mirror of
https://github.com/bitwarden/server.git
synced 2025-04-28 08:12:22 -05:00
Add env variable to override /installations domain (#5669)
* Add env variable to override /installations domain
This commit is contained in:
parent
4320649468
commit
2644efc2b7
@ -278,6 +278,13 @@ public class Program
|
|||||||
url = "https://api.bitwarden.com/installations/";
|
url = "https://api.bitwarden.com/installations/";
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
string installationUrl = Environment.GetEnvironmentVariable("BW_INSTALLATION_URL");
|
||||||
|
if (!string.IsNullOrEmpty(installationUrl))
|
||||||
|
{
|
||||||
|
url = $"{installationUrl}/installations/";
|
||||||
|
}
|
||||||
|
|
||||||
var response = new HttpClient().GetAsync(url + _context.Install.InstallationId).GetAwaiter().GetResult();
|
var response = new HttpClient().GetAsync(url + _context.Install.InstallationId).GetAwaiter().GetResult();
|
||||||
|
|
||||||
if (!response.IsSuccessStatusCode)
|
if (!response.IsSuccessStatusCode)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user