refactor(front/Docker): cleanup nginx-based container
This commit is contained in:
parent
3f04429993
commit
6df36f519a
4 changed files with 31 additions and 38 deletions
|
|
@ -15,20 +15,15 @@ RUN yarn build:deployment
|
|||
FROM nginx:1.23.1-alpine as final
|
||||
|
||||
COPY --from=builder /app/dist /usr/share/nginx/html
|
||||
COPY docker/funkwhale.template /etc/nginx/conf.d/funkwhale.template
|
||||
COPY docker/funkwhale.conf.template /etc/nginx/templates/default.conf.template
|
||||
COPY docker/funkwhale_proxy.conf /etc/nginx/funkwhale_proxy.conf
|
||||
COPY docker/entrypoint.sh /docker-entrypoint.d/99-funkwhale.sh
|
||||
|
||||
# Allow running as non-root for custom setups
|
||||
RUN mkdir -p /var/log/nginx /var/cache/nginx /var/run/nginx && \
|
||||
chown -R nginx:nginx /var/log/nginx /var/run/nginx /var/cache/nginx /etc/nginx && \
|
||||
sed -e 's#/var/run/nginx.pid#/var/run/nginx/nginx.pid#' -i /etc/nginx/nginx.conf
|
||||
|
||||
CMD ["sh", "-c", "envsubst \"`env | awk -F = '{printf \" $$%s\", $$1}'`\" \
|
||||
< /etc/nginx/conf.d/funkwhale.template \
|
||||
> /etc/nginx/conf.d/default.conf \
|
||||
&& cat /etc/nginx/conf.d/default.conf \
|
||||
&& nginx -g 'daemon off;'"]
|
||||
|
||||
ENV FUNKWHALE_API_HOST=api
|
||||
ENV FUNKWHALE_API_PORT=5000
|
||||
ENV AWS_S3_ENDPOINT_URL=
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue