refactor(docker): use templating to handle env variables (#8878)

Refs #8877
This commit is contained in:
Vladimír Gorej
2023-06-02 16:05:08 +02:00
committed by GitHub
parent b017858fe1
commit 1f7bb89217
4 changed files with 34 additions and 44 deletions

View File

@@ -0,0 +1,42 @@
types {
text/plain yaml;
text/plain yml;
}
gzip on;
gzip_static on;
gzip_disable "msie6";
gzip_vary on;
gzip_types text/plain text/css application/javascript;
map $request_method $access_control_max_age {
OPTIONS 1728000; # 20 days
}
server_tokens off; # Hide Nginx version
server {
listen $PORT;
server_name localhost;
index index.html index.htm;
location $BASE_URL {
absolute_redirect off;
alias /usr/share/nginx/html/;
expires 1d;
location ~ swagger-initializer.js {
expires -1;
include templates/cors.conf;
}
location ~* \.(?:json|yml|yaml)$ {
#SWAGGER_ROOT
expires -1;
include templates/cors.conf;
}
include templates/cors.conf;
}
}