network isolation

This commit is contained in:
Yax 2021-12-12 12:02:11 +01:00
parent f8c8767a83
commit 2ea59dfae3
19 changed files with 121 additions and 42 deletions

View file

@ -13,7 +13,7 @@ services:
volumes:
- photoview_db_data:/var/lib/mysql
networks:
- srv
- photo-backend
photoview:
container_name: photoview
@ -24,7 +24,8 @@ services:
depends_on:
- photoview-db
networks:
- srv
- photo-backend
- photo-frontend
environment:
- PHOTOVIEW_DATABASE_DRIVER=mysql
- PHOTOVIEW_MYSQL_URL=photoview:photosecret@tcp(photoview-db)/photoview
@ -60,9 +61,10 @@ services:
- SYS_ADMIN
labels:
- traefik.enable=true
- traefik.http.routers.pigallery_config.rule=Host(`${HOST_PHOTOVIEW}.${DOMAIN}`)
- traefik.http.routers.pigallery_config.entrypoints=https
- traefik.http.routers.pigallery_config.tls=true
- traefik.http.routers.photo.rule=Host(`${HOST_PHOTOVIEW}.${DOMAIN}`)
- traefik.http.routers.photo.entrypoints=https
- traefik.http.routers.photo.tls=true
- traefik.docker.network=photo-frontend
volumes:
photoview_db_data:

View file

@ -27,9 +27,10 @@ services:
disable: true
labels:
- traefik.enable=true
- traefik.http.routers.pigallery_config.rule=Host(`${HOST_PIGALLERY}.${DOMAIN}`)
- traefik.http.routers.pigallery_config.entrypoints=https
- traefik.http.routers.pigallery_config.tls=true
- traefik.http.routers.photo.rule=Host(`${HOST_PIGALLERY}.${DOMAIN}`)
- traefik.http.routers.photo.entrypoints=https
- traefik.http.routers.photo.tls=true
- traefik.docker.network=photo-frontend
volumes:
pigallerydb_data: