Merge remote-tracking branch 'origin/staging' into develop

This commit is contained in:
Alejandro Alonso 2023-03-08 07:25:19 +01:00
commit c3ce0eb794
18 changed files with 60 additions and 26 deletions

View file

@ -8,7 +8,7 @@ RUN set -ex; \
ADD ./bundle-frontend/ /var/www/app/
ADD ./files/config.js /var/www/app/js/config.js
ADD ./files/nginx.conf /etc/nginx/nginx.conf
ADD ./files/nginx.conf /etc/nginx/nginx.conf.template
ADD ./files/nginx-entrypoint.sh /entrypoint.sh
ENTRYPOINT ["/bin/bash", "/entrypoint.sh"]

View file

@ -1,9 +1,5 @@
#!/usr/bin/env bash
log() {
echo "[$(date +%Y-%m-%dT%H:%M:%S%:z)] $*"
}
#########################################
## App Frontend config
#########################################
@ -17,4 +13,15 @@ update_flags() {
}
update_flags /var/www/app/js/config.js
#########################################
## Nginx Config
#########################################
export PENPOT_BACKEND_URI=${PENPOT_BACKEND_URI:-http://penpot-backend:6060};
export PENPOT_EXPORTER_URI=${PENPOT_EXPORTER_URI:-http://penpot-exporter};
envsubst "\$PENPOT_BACKEND_URI,\$PENPOT_EXPORTER_URI" < /etc/nginx/nginx.conf.template > /etc/nginx/nginx.conf
exec "$@";

View file

@ -82,7 +82,7 @@ http {
}
location /assets {
proxy_pass http://penpot-backend:6060/assets;
proxy_pass $PENPOT_BACKEND_URI/assets;
recursive_error_pages on;
proxy_intercept_errors on;
error_page 301 302 307 = @handle_redirect;
@ -95,21 +95,17 @@ http {
}
location /api/export {
proxy_pass http://penpot-exporter:6061;
proxy_pass $PENPOT_EXPORTER_URI;
}
location /api {
proxy_pass http://penpot-backend:6060/api;
proxy_pass $PENPOT_BACKEND_URI/api;
}
# location /admin {
# proxy_pass http://penpot-admin:6065/admin;
# }
location /ws/notifications {
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_pass http://penpot-backend:6060/ws/notifications;
proxy_pass $PENPOT_BACKEND_URI/ws/notifications;
}
location / {