From 570f89b4e352ee22a5ce32e3591084f1ac6cfaf7 Mon Sep 17 00:00:00 2001 From: clchieu Date: Tue, 2 Apr 2024 18:18:02 +0200 Subject: [PATCH] =?UTF-8?q?Ajout=20de=20l'utilisation=20de=20la=20variable?= =?UTF-8?q?=20d'environnement=20au=20moment=20de=20la=20cr=C3=A9ation=20de?= =?UTF-8?q?=20l'api?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- API_SQLuedo/API/Program.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/API_SQLuedo/API/Program.cs b/API_SQLuedo/API/Program.cs index 3977b7a..45dbd20 100644 --- a/API_SQLuedo/API/Program.cs +++ b/API_SQLuedo/API/Program.cs @@ -42,6 +42,7 @@ builder.Services.AddDbContext(options => if (builder.Environment.IsProduction()) { Console.WriteLine("I am in production mode"); + options.UseNpgsql(Environment.GetEnvironmentVariable("CO_STRING", EnvironmentVariableTarget.Process)); } else {