mirror of
https://github.com/bitwarden/server.git
synced 2025-07-01 16:12:49 -05:00
Platform/pm 2138/add nginx to known proxies (#3012)
* Add nginx to known proxies * Only add nginx proxy if standard self host deployment * Style changes * Add forwarded headers config to events server * Add known proxy forwarding to missing services * Catch DNS errors in adding nginx proxy * Update src/SharedWeb/Utilities/ServiceCollectionExtensions.cs Co-authored-by: Justin Baur <19896123+justindbaur@users.noreply.github.com> --------- Co-authored-by: Justin Baur <19896123+justindbaur@users.noreply.github.com>
This commit is contained in:
@ -93,6 +93,12 @@ public class Startup
|
||||
// Add general security headers
|
||||
app.UseMiddleware<SecurityHeadersMiddleware>();
|
||||
|
||||
// Forwarding Headers
|
||||
if (globalSettings.SelfHosted)
|
||||
{
|
||||
app.UseForwardedHeaders(globalSettings);
|
||||
}
|
||||
|
||||
if (env.IsDevelopment())
|
||||
{
|
||||
app.UseDeveloperExceptionPage();
|
||||
|
Reference in New Issue
Block a user