chore: move pid file to /var/tmp/nginx and fix http proxy_pass
All checks were successful
continuous-integration/drone/push Build is passing
continuous-integration/drone/tag Build is passing

This commit is contained in:
Robert Kaussow 2023-09-25 22:44:48 +02:00
parent 3ee6e3c6ff
commit 081e7d2f41
Signed by: xoxys
GPG Key ID: 4E692A2EAECC03C0
3 changed files with 4 additions and 4 deletions

View File

@ -35,9 +35,7 @@ RUN addgroup -g 1001 -S nginx && \
ADD overlay/ /
RUN mkdir -p /var/www /etc/nginx-s3 /etc/nginx/conf.d /var/tmp/nginx /var/cache/nginx && \
touch /run/nginx.pid && \
touch /etc/nginx/conf.d/vhosts.conf && \
chown nginx /run/nginx.pid && \
chown -R nginx /var/tmp/nginx /var/cache/nginx && \
chown -R nginx:nginx /var/www && \
chown -R root:nginx /etc/nginx /etc/nginx/conf.d && \

View File

@ -1,5 +1,5 @@
worker_processes 1;
pid /var/run/nginx.pid;
pid /var/tmp/nginx/nginx.pid;
error_log stderr error;
events {

View File

@ -50,13 +50,15 @@ server {
{{ end -}}
proxy_pass https://backend_s3_{{ $this.bucket }}/{{ $this.bucket }}/${repo}$uri;
{{- if $this.upstream_use_tls }}
proxy_pass https://backend_s3_{{ $this.bucket }}/{{ $this.bucket }}/${repo}$uri;
proxy_ssl_name {{ $upstream_host }};
proxy_ssl_server_name on;
proxy_ssl_verify on;
proxy_ssl_trusted_certificate /etc/ssl/certs/ca-certificates.crt;
proxy_ssl_protocols {{ $this.proxy_ssl_protocols }};
{{- else }}
proxy_pass http://backend_s3_{{ $this.bucket }}/{{ $this.bucket }}/${repo}$uri;
{{- end }}
proxy_http_version 1.1;