2021-08-20 11:16:40 -04:00
|
|
|
# docker-nginx-auto
|
|
|
|
|
2021-08-20 17:02:57 -04:00
|
|
|
Nginx with tricks
|
|
|
|
|
|
|
|
- OpenResty
|
|
|
|
- Snippets for TLS/SSL, gzip, reverse proxy, websocket proxy, and proxy cache
|
|
|
|
- Automatic Let's Encrypt certificate
|
|
|
|
- Automatic reload on configuration change
|
|
|
|
|
|
|
|
Production:
|
|
|
|
|
|
|
|
```sh
|
|
|
|
docker run -d --name=docker-nginx-auto \
|
|
|
|
-e ACME_EMAIL=user@host \
|
|
|
|
-p 80:80 -p 443:443 \
|
|
|
|
-v nginx-config:/usr/local/openresty/nginx/conf \
|
|
|
|
docker-nginx-auto
|
|
|
|
```
|
|
|
|
|
|
|
|
Staging:
|
|
|
|
|
|
|
|
```sh
|
|
|
|
docker run -d --name=docker-nginx-auto \
|
|
|
|
-e ACME_STAGING=true \
|
|
|
|
-p 80:80 -p 443:443 \
|
|
|
|
-v nginx-config:/usr/local/openresty/nginx/conf \
|
|
|
|
docker-nginx-auto
|
|
|
|
```
|