Update proxying, swap /zammad and /link

This commit is contained in:
Darren Clarke 2025-02-06 13:03:31 +01:00
parent 2fd85f045c
commit 9283227074
24 changed files with 3317 additions and 2822 deletions

View file

@ -16,7 +16,15 @@ USER root
RUN sed -i '/script\/build\/cleanup\.sh/d' contrib/docker/setup.sh
RUN contrib/docker/setup.sh builder
ARG EMBEDDED=false
RUN if [ "$EMBEDDED" = "true" ] ; then sed -i '/proxy_set_header X-Forwarded-User "";/d' ${ZAMMAD_DIR}/contrib/nginx/zammad.conf; fi
RUN if [ "$EMBEDDED" = "true" ] ; then sed -i '/location \/ {/i \
\ \n\
\ location /link {\n\
\ proxy_pass http://link;\n\
\ proxy_set_header Host $host;\n\
\ proxy_set_header X-Real-IP $remote_addr;\n\
\ proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;\n\
\ proxy_set_header X-Forwarded-Proto https;\n\
\ }\n' ${ZAMMAD_DIR}/contrib/nginx/zammad.conf; fi
RUN sed -i '/^[[:space:]]*# es config/a\
echo "about to reinstall..."\n\
bundle exec rails runner /opt/zammad/contrib/link/setup.rb\n\