cruizba 6a73083e7b openvidu-deployment: General updates in nginx and public ip discovering:
- Add option to redirect www to non-www (REDIRECT_WWW).
- Add endpoint to check nginx workers.
- Custom virtual hosts (Server blocks) can be added by the user to create custom rules in `/opt/openvidu/custom-nginx-vhost`.
- Parametrize `worker_connections` in nginx.conf (WORKER_CONNECTIONS)
- Improve `discover_my_public_ip.sh` to use dns servers instead of http servers
- Posibility to autodiscover ipv6 if available by using `PUBLIC_IP=auto-ipv6` in nginx, `TURN_PUBLIC_IP=auto-ipv6` in coturn and `COTURN_IP=auto-ipv6` in openvidu-server.
By default ipv4 is used.
2020-11-02 19:46:59 +01:00

32 lines
779 B
Docker

FROM nginx:1.18.0-alpine
# Install required software
RUN apk update && \
apk add bash \
certbot \
openssl \
apache2-utils \
bind-tools \
perl pcre grep && \
rm -rf /var/cache/apk/*
# Default nginx conf
COPY ./default.conf /etc/nginx/conf.d/default.conf
COPY ./default_nginx_conf /default_nginx_conf
# Entrypoint and discover public ip scripts
COPY ./discover_my_public_ip.sh /usr/local/bin
# Copy nginx.conf
COPY ./nginx.conf /etc/nginx/nginx.conf
# Entrypoint
COPY ./entrypoint.sh /usr/local/bin
RUN mkdir -p /var/www/certbot && \
mkdir -p /etc/nginx/vhost.d/ && \
chmod +x /usr/local/bin/entrypoint.sh && \
chmod +x /usr/local/bin/discover_my_public_ip.sh
CMD /usr/local/bin/entrypoint.sh