For reference when raising the Nginx Proxy and companion Let's Encrypt Setup.
- Nginx Proxy Docker Image
- Let's Encrypt Nginx Proxy Companion -- though this apparently was replaced?
For reference when raising the Nginx Proxy and companion Let's Encrypt Setup.
| #!/bin/bash | |
| docker run -d \ | |
| --net my-nginx-proxy-network \ | |
| --expose 3002 \ | |
| -e PORT=3002 \ | |
| -e VIRTUAL_HOST=<MY-URL>.com \ | |
| -e LETSENCRYPT_HOST=<MY-URL>.com \ | |
| -e VIRTUAL_PORT=3002 \ | |
| -e LETSENCRYPT_EMAIL=my@email.com \ | |
| -v .:/html \ | |
| --name some-landing-page \ | |
| vasaulys/quark-server |
| #!/bin/bash | |
| echo "### Generating Nginx Proxy" | |
| docker run --detach \ | |
| --net my-nginx-proxy-network \ | |
| --name my-nginx-proxy \ | |
| --publish 80:80 \ | |
| --publish 443:443 \ | |
| --volume certs:/etc/nginx/certs \ | |
| --volume vhost:/etc/nginx/vhost.d \ | |
| --volume html:/usr/share/nginx/html \ | |
| --volume /var/run/docker.sock:/tmp/docker.sock:ro \ | |
| jwilder/nginx-proxy | |
| echo "### generating let's encrypt companion" | |
| docker run --detach \ | |
| --net my-nginx-proxy-network \ | |
| --name nginx-proxy-letsencrypt \ | |
| --volumes-from my-nginx-proxy \ | |
| --volume /var/run/docker.sock:/var/run/docker.sock:ro \ | |
| --volume acme:/etc/acme.sh \ | |
| --env "DEFAULT_EMAIL=vincent@saulys.me" \ | |
| jrcs/letsencrypt-nginx-proxy-companion | |
| echo "### Check if you need to connect to other networks" | |
| echo "docker network connect my-other-network my-nginx-proxy" | |
| echo "this will allow nginx proxy to connect to containers on other networks" |