mirror of
https://github.com/OpenBankProject/API-Manager.git
synced 2026-02-06 10:59:00 +00:00
fix container nginx conf
This commit is contained in:
parent
878e807a74
commit
714bd27f0b
2
.github/Dockerfile_nginx_OC
vendored
2
.github/Dockerfile_nginx_OC
vendored
@ -15,7 +15,7 @@ RUN python ./apimanager/manage.py collectstatic --noinput
|
|||||||
FROM registry.access.redhat.com/ubi9/nginx-120
|
FROM registry.access.redhat.com/ubi9/nginx-120
|
||||||
USER 0
|
USER 0
|
||||||
RUN dnf update -y
|
RUN dnf update -y
|
||||||
ADD .github/apimanager.conf "${NGINX_DEFAULT_CONF_PATH}"
|
ADD .github/apimanager_oc.conf "${NGINX_DEFAULT_CONF_PATH}"
|
||||||
COPY --from=builder /app/apimanager/static /opt/app-root/src
|
COPY --from=builder /app/apimanager/static /opt/app-root/src
|
||||||
RUN chgrp -R 0 /opt/app-root/src/ && chmod -R g+rwX /opt/app-root/src/
|
RUN chgrp -R 0 /opt/app-root/src/ && chmod -R g+rwX /opt/app-root/src/
|
||||||
USER 1001
|
USER 1001
|
||||||
|
|||||||
6
.github/apimanager.conf
vendored
6
.github/apimanager.conf
vendored
@ -1,5 +1,4 @@
|
|||||||
server {
|
|
||||||
listen 8080;
|
|
||||||
server_name apimanager;
|
server_name apimanager;
|
||||||
|
|
||||||
location / {
|
location / {
|
||||||
@ -19,5 +18,4 @@ server {
|
|||||||
}
|
}
|
||||||
location /static {
|
location /static {
|
||||||
alias /usr/share/nginx/html;
|
alias /usr/share/nginx/html;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
20
.github/apimanager_oc.conf
vendored
Normal file
20
.github/apimanager_oc.conf
vendored
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
|
||||||
|
server_name apimanager;
|
||||||
|
|
||||||
|
location / {
|
||||||
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
|
# enable this if and only if you use HTTPS
|
||||||
|
# proxy_set_header X-Forwarded-Proto https;
|
||||||
|
proxy_set_header Host $http_host;
|
||||||
|
proxy_redirect off;
|
||||||
|
proxy_pass http://127.0.0.1:8000;
|
||||||
|
}
|
||||||
|
|
||||||
|
location /en/static {
|
||||||
|
alias /opt/app-root/src;
|
||||||
|
}
|
||||||
|
location /es/static {
|
||||||
|
alias /opt/app-root/src;
|
||||||
|
}
|
||||||
|
location /static {
|
||||||
|
alias /opt/app-root/src;
|
||||||
Loading…
Reference in New Issue
Block a user