mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-07-06 13:11:13 -07:00
feat: Adding postgres support to ombi (beta) (#5050)
This commit is contained in:
parent
8ff7d9995d
commit
f8c61027bf
22 changed files with 5660 additions and 12 deletions
17
src/Ombi.Store/Context/Postgres/PostgresModuleInitializer.cs
Normal file
17
src/Ombi.Store/Context/Postgres/PostgresModuleInitializer.cs
Normal file
|
@ -0,0 +1,17 @@
|
|||
using System;
|
||||
using System.Runtime.CompilerServices;
|
||||
|
||||
namespace Ombi.Store.Context.Postgres;
|
||||
|
||||
public static class PostgresModuleInitializer
|
||||
{
|
||||
#pragma warning disable CA2255
|
||||
// This is required to ensure that Npgsql uses a timestamp behavior that does not require a timezone
|
||||
// Reference: https://stackoverflow.com/a/73586129
|
||||
[ModuleInitializer]
|
||||
#pragma warning restore CA2255
|
||||
public static void Initialize()
|
||||
{
|
||||
AppContext.SetSwitch("Npgsql.EnableLegacyTimestampBehavior", true);
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue