Skip to content

Instantly share code, notes, and snippets.

@smyth64
Last active April 20, 2018 13:25
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save smyth64/13699b98e03b789a4bb3c9de26be812a to your computer and use it in GitHub Desktop.
Save smyth64/13699b98e03b789a4bb3c9de26be812a to your computer and use it in GitHub Desktop.
Fast Docker Letsencrypt Reverse Proxy
```
docker network create webproxy &&
git clone https://github.com/evertramos/docker-compose-letsencrypt-nginx-proxy-companion proxy &&
cd proxy &&
cp .env.sample .env &&
sed -i -e 's/\/path\/to\/your\/nginx\/data/\.\/data/g' .env &&
docker-compose up -d
```
An example of a docker-compose project looks like this:
```
version: '3'
services:
web:
image: node
command: npm run dev
restart: always
expose:
- '8080'
environment:
VIRTUAL_HOST: 'www.domain.de,domain.de'
VIRTUAL_PORT: 8080
LETSENCRYPT_HOST: 'www.domain.de,domain.de'
LETSENCRYPT_EMAIL: 'info@adminofdomain.de'
working_dir: /app
volumes:
- '.:/app'
networks:
- reverseproxy
networks:
reverseproxy:
external:
name: webproxy
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment