chore: add docker-compose

This commit is contained in:
Dmitriy Pleshevskiy 2022-06-03 14:03:58 +03:00
parent 378a2e093e
commit 07ac383798
Signed by: pleshevskiy
GPG key ID: 1B59187B161C0215
2 changed files with 35 additions and 15 deletions

19
.gitignore vendored
View file

@ -4,22 +4,11 @@
!/.vscode
# ignores
!/.gitignore
!/.dockerignore
# docker
!/Dockerfile
# makefile
!/makefile
!/*ignore
# config
!/.eslintrc.yml
!/tsconfig.json
# node modules
!/package.json
!/package-lock.json
!/*file
!/*.yml
!/*.json
# sources
!/src

31
docker-compose.yml Normal file
View file

@ -0,0 +1,31 @@
version: "3.9"
networks:
rp_public:
external: true
services:
site:
image: pleshevski
networks:
- rp_public
deploy:
replicas: 1
endpoint_mode: vip
update_config:
order: start-first
rollback_config:
order: start-first
labels:
- traefik.enable=true
- traefik.docker.network=rp_public
- traefik.constraint-label=rp_public
- traefik.http.routers.pleshevski_http.rule=Host(`pleshevski.ru`)
- traefik.http.routers.pleshevski_http.entrypoints=http
- traefik.http.routers.pleshevski_http.middlewares=https_redirect
- traefik.http.routers.pleshevski_https.rule=Host(`pleshevski.ru`)
- traefik.http.routers.pleshevski_https.entrypoints=https
- traefik.http.routers.pleshevski_https.tls=true
- traefik.http.routers.pleshevski_https.tls.certresolver=le
- traefik.http.services.pleshevski.loadbalancer.server.port=30000