Compare commits
4 commits
Author | SHA1 | Date | |
---|---|---|---|
![]() |
856280f228 | ||
![]() |
318e367f63 | ||
![]() |
740fa221bb | ||
![]() |
67d2ebbc59 |
15 changed files with 23 additions and 636 deletions
23
0/docker-compose.networks.yml
Normal file
23
0/docker-compose.networks.yml
Normal file
|
@ -0,0 +1,23 @@
|
||||||
|
version: '3.8'
|
||||||
|
|
||||||
|
networks:
|
||||||
|
dmz:
|
||||||
|
name: dmz
|
||||||
|
blog-frontend:
|
||||||
|
name: blog-frontend
|
||||||
|
blog-backend:
|
||||||
|
name: blog-backend
|
||||||
|
glances-frontend:
|
||||||
|
name: glances-frontend
|
||||||
|
portainer-frontend:
|
||||||
|
name: portainer-frontend
|
||||||
|
selfoss-frontend:
|
||||||
|
name: selfoss-frontend
|
||||||
|
shaarli-frontend:
|
||||||
|
name: shaarli-frontend
|
||||||
|
source-frontend:
|
||||||
|
name: source-frontend
|
||||||
|
wallabag-frontend:
|
||||||
|
name: wallabag-frontend
|
||||||
|
wwww-frontend:
|
||||||
|
name: wwww-frontend
|
|
@ -1,28 +0,0 @@
|
||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
|
||||||
baikal:
|
|
||||||
container_name: baikal
|
|
||||||
image: ckulka/baikal:nginx
|
|
||||||
networks:
|
|
||||||
- baikal-frontend
|
|
||||||
expose:
|
|
||||||
- 80
|
|
||||||
restart: unless-stopped
|
|
||||||
volumes:
|
|
||||||
- baikal_data:/var/www/baikal/Specific:rw
|
|
||||||
- baikal_config:/var/www/baikal/config:rw
|
|
||||||
labels:
|
|
||||||
- traefik.enable=true
|
|
||||||
- traefik.http.routers.baikal.rule=Host(`${HOST_BAIKAL}.${DOMAIN}`)
|
|
||||||
- traefik.http.routers.baikal.entrypoints=https
|
|
||||||
- traefik.http.routers.baikal.tls=true
|
|
||||||
- traefik.docker.network=baikal-frontend
|
|
||||||
|
|
||||||
networks:
|
|
||||||
baikal-frontend:
|
|
||||||
name: baikal-frontend
|
|
||||||
|
|
||||||
volumes:
|
|
||||||
baikal_config:
|
|
||||||
baikal_data:
|
|
|
@ -1,55 +0,0 @@
|
||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
|
||||||
deluge:
|
|
||||||
container_name: deluge
|
|
||||||
image: linuxserver/deluge
|
|
||||||
restart: unless-stopped
|
|
||||||
networks:
|
|
||||||
- deluge-frontend
|
|
||||||
environment:
|
|
||||||
DELUGE_LOGLEVEL: info
|
|
||||||
TZ: ${TZ}
|
|
||||||
expose:
|
|
||||||
- 8112
|
|
||||||
ports:
|
|
||||||
- ${DELUGE_TORRENT_PORT}:${DELUGE_TORRENT_PORT}/tcp
|
|
||||||
- ${DELUGE_TORRENT_PORT}:${DELUGE_TORRENT_PORT}/udp
|
|
||||||
volumes:
|
|
||||||
- deluge_config:/config:rw
|
|
||||||
- deluge_downloads:/downloads:rw
|
|
||||||
labels:
|
|
||||||
- traefik.enable=true
|
|
||||||
- traefik.http.routers.deluge.rule=Host(`${HOST_WWW}.${DOMAIN}`) && PathPrefix(`${PATH_DELUGE}`)
|
|
||||||
- traefik.http.routers.deluge.entrypoints=https
|
|
||||||
- traefik.http.routers.deluge.tls=true
|
|
||||||
- traefik.http.services.deluge.loadbalancer.server.port=8112
|
|
||||||
- traefik.http.routers.deluge.middlewares=delugeHeader,sameOriginHeader,delugeRedir,delugePStrip
|
|
||||||
- traefik.http.middlewares.delugeHeader.headers.customrequestheaders.X-Deluge-Base=${PATH_DELUGE}/
|
|
||||||
- traefik.http.middlewares.sameOriginHeader.headers.customrequestheaders.X-Frame-Options=SAMEORIGIN
|
|
||||||
- traefik.http.middlewares.delugePStrip.stripprefix.prefixes=${PATH_DELUGE}
|
|
||||||
- traefik.http.middlewares.delugeRedir.redirectregex.regex=^(.*)${PATH_DELUGE}$$
|
|
||||||
- traefik.http.middlewares.delugeRedir.redirectregex.replacement=$${1}${PATH_DELUGE}/
|
|
||||||
- traefik.docker.network=deluge-frontend
|
|
||||||
|
|
||||||
torrent:
|
|
||||||
container_name: torrent
|
|
||||||
image: kianby/nginx-streaming
|
|
||||||
restart: unless-stopped
|
|
||||||
networks:
|
|
||||||
- dmz
|
|
||||||
volumes:
|
|
||||||
- deluge_downloads:/downloads:ro
|
|
||||||
expose:
|
|
||||||
- 80
|
|
||||||
# shortcut to bypass traefik limitation
|
|
||||||
ports:
|
|
||||||
- ${DOWNLOAD_HTTP_PORT}:80
|
|
||||||
|
|
||||||
networks:
|
|
||||||
deluge-frontend:
|
|
||||||
name: deluge-frontend
|
|
||||||
|
|
||||||
volumes:
|
|
||||||
deluge_config:
|
|
||||||
deluge_downloads:
|
|
|
@ -1,26 +0,0 @@
|
||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
|
||||||
dokuwiki:
|
|
||||||
image: linuxserver/dokuwiki
|
|
||||||
container_name: dokuwiki
|
|
||||||
restart: unless-stopped
|
|
||||||
expose:
|
|
||||||
- 80
|
|
||||||
environment:
|
|
||||||
- TZ=${TZ}
|
|
||||||
- APP_URL=/ #optional
|
|
||||||
volumes:
|
|
||||||
- ${ROOT_INSTALL}/data/dokuwiki:/config
|
|
||||||
networks:
|
|
||||||
- dokuwiki-frontend
|
|
||||||
labels:
|
|
||||||
- traefik.enable=true
|
|
||||||
- traefik.http.routers.dokuwiki.rule=Host(`${HOST_DOKUWIKI}.${DOMAIN}`)
|
|
||||||
- traefik.http.routers.dokuwiki.entrypoints=https
|
|
||||||
- traefik.http.routers.dokuwiki.tls=true
|
|
||||||
- traefik.docker.network=dokuwiki-frontend
|
|
||||||
|
|
||||||
networks:
|
|
||||||
dokuwiki-frontend:
|
|
||||||
name: dokuwiki-frontend
|
|
|
@ -1,57 +0,0 @@
|
||||||
version: '3.8'
|
|
||||||
services:
|
|
||||||
netdata:
|
|
||||||
image: netdata/netdata
|
|
||||||
container_name: netdata
|
|
||||||
hostname: ${HOST_NETDATA}.${DOMAIN}
|
|
||||||
expose:
|
|
||||||
- 19999
|
|
||||||
restart: unless-stopped
|
|
||||||
cap_add:
|
|
||||||
- SYS_PTRACE
|
|
||||||
security_opt:
|
|
||||||
- apparmor:unconfined
|
|
||||||
environment:
|
|
||||||
- DOCKER_HOST=docker-proxy:2375
|
|
||||||
volumes:
|
|
||||||
- netdataconfig:/etc/netdata
|
|
||||||
- netdatalib:/var/lib/netdata
|
|
||||||
- netdatacache:/var/cache/netdata
|
|
||||||
- /etc/passwd:/host/etc/passwd:ro
|
|
||||||
- /etc/group:/host/etc/group:ro
|
|
||||||
- /proc:/host/proc:ro
|
|
||||||
- /sys:/host/sys:ro
|
|
||||||
- /etc/os-release:/host/etc/os-release:ro
|
|
||||||
networks:
|
|
||||||
- netdata-frontend
|
|
||||||
- netdata-backend
|
|
||||||
labels:
|
|
||||||
- traefik.enable=true
|
|
||||||
- traefik.http.routers.netdata.rule=Host(`${HOST_NETDATA}.${DOMAIN}`)
|
|
||||||
- traefik.http.routers.netdata.entrypoints=https
|
|
||||||
- traefik.http.routers.netdata.tls=true
|
|
||||||
- traefik.http.routers.netdata.middlewares=auth
|
|
||||||
- traefik.http.middlewares.auth.basicauth.users=${BASIC_AUTH}
|
|
||||||
- traefik.docker.network=netdata-frontend
|
|
||||||
healthcheck:
|
|
||||||
disable: true
|
|
||||||
docker-proxy:
|
|
||||||
image: tecnativa/docker-socket-proxy
|
|
||||||
container_name: docker-proxy
|
|
||||||
volumes:
|
|
||||||
- /var/run/docker.sock:/var/run/docker.sock:ro
|
|
||||||
environment:
|
|
||||||
- CONTAINERS=1
|
|
||||||
networks:
|
|
||||||
- netdata-backend
|
|
||||||
|
|
||||||
networks:
|
|
||||||
netdata-frontend:
|
|
||||||
name: netdata-frontend
|
|
||||||
netdata-backend:
|
|
||||||
name: netdata-backend
|
|
||||||
|
|
||||||
volumes:
|
|
||||||
netdataconfig:
|
|
||||||
netdatalib:
|
|
||||||
netdatacache:
|
|
|
@ -1,35 +0,0 @@
|
||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
|
||||||
lychee:
|
|
||||||
container_name: lychee
|
|
||||||
environment:
|
|
||||||
- PHP_TZ=${TZ}
|
|
||||||
- TIMEZONE=${TZ}
|
|
||||||
image: lycheeorg/lychee
|
|
||||||
networks:
|
|
||||||
- photo-frontend
|
|
||||||
expose:
|
|
||||||
- 80
|
|
||||||
restart: unless-stopped
|
|
||||||
volumes:
|
|
||||||
- lychee_conf:/conf
|
|
||||||
- lychee_uploads:/uploads
|
|
||||||
- lychee_sym:/sym
|
|
||||||
labels:
|
|
||||||
- traefik.enable=true
|
|
||||||
- traefik.http.routers.photo.rule=Host(`${HOST_LYCHEE}.${DOMAIN}`)
|
|
||||||
- traefik.http.routers.photo.entrypoints=https
|
|
||||||
- traefik.http.routers.photo.tls=true
|
|
||||||
- traefik.docker.network=photo-frontend
|
|
||||||
|
|
||||||
networks:
|
|
||||||
photo-frontend:
|
|
||||||
name: photo-frontend
|
|
||||||
photo-backend:
|
|
||||||
name: photo-backend
|
|
||||||
|
|
||||||
volumes:
|
|
||||||
lychee_conf:
|
|
||||||
lychee_uploads:
|
|
||||||
lychee_sym:
|
|
|
@ -1,71 +0,0 @@
|
||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
|
||||||
postgres:
|
|
||||||
container_name: photonix-postgres
|
|
||||||
image: postgres:11.1-alpine
|
|
||||||
environment:
|
|
||||||
POSTGRES_DB: photonix
|
|
||||||
POSTGRES_PASSWORD: password
|
|
||||||
volumes:
|
|
||||||
- photonix_db:/var/lib/postgresql/data
|
|
||||||
networks:
|
|
||||||
- photo-backend
|
|
||||||
|
|
||||||
redis:
|
|
||||||
container_name: photonix-redis
|
|
||||||
image: redis:6.2.2
|
|
||||||
networks:
|
|
||||||
- photo-backend
|
|
||||||
|
|
||||||
photonix:
|
|
||||||
container_name: photonix
|
|
||||||
image: photonixapp/photonix:latest
|
|
||||||
expose:
|
|
||||||
- 80
|
|
||||||
environment:
|
|
||||||
ENV: prd
|
|
||||||
POSTGRES_HOST: postgres
|
|
||||||
POSTGRES_DB: photonix
|
|
||||||
POSTGRES_USER: postgres
|
|
||||||
POSTGRES_PASSWORD: password
|
|
||||||
REDIS_HOST: redis
|
|
||||||
ALLOWED_HOSTS: '*'
|
|
||||||
# More configuration options here: https://photonix.org/docs/configuration/
|
|
||||||
volumes:
|
|
||||||
# - ./data/photos:/data/photos
|
|
||||||
- photonix_raw_photos:/data/raw-photos-processed
|
|
||||||
- photonix_cache:/data/cache
|
|
||||||
- photonix_models:/data/models
|
|
||||||
- type: bind
|
|
||||||
source: ${ROOT_INSTALL}/data/seafile-fuse
|
|
||||||
target: /seahub
|
|
||||||
bind:
|
|
||||||
propagation: rslave
|
|
||||||
privileged: true
|
|
||||||
cap_add:
|
|
||||||
- SYS_ADMIN
|
|
||||||
depends_on:
|
|
||||||
- postgres
|
|
||||||
- redis
|
|
||||||
networks:
|
|
||||||
- photo-backend
|
|
||||||
- photo-frontend
|
|
||||||
labels:
|
|
||||||
- traefik.enable=true
|
|
||||||
- traefik.http.routers.photo.rule=Host(`${HOST_PHOTONIX}.${DOMAIN}`)
|
|
||||||
- traefik.http.routers.photo.entrypoints=https
|
|
||||||
- traefik.http.routers.photo.tls=true
|
|
||||||
- traefik.docker.network=photo-frontend
|
|
||||||
|
|
||||||
networks:
|
|
||||||
photo-frontend:
|
|
||||||
name: photo-frontend
|
|
||||||
photo-backend:
|
|
||||||
name: photo-backend
|
|
||||||
|
|
||||||
volumes:
|
|
||||||
photonix_raw_photos:
|
|
||||||
photonix_cache:
|
|
||||||
photonix_models:
|
|
||||||
photonix_db:
|
|
|
@ -1,77 +0,0 @@
|
||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
|
||||||
photoview-db:
|
|
||||||
container_name: photoview-db
|
|
||||||
image: mariadb:10.5
|
|
||||||
restart: unless-stopped
|
|
||||||
environment:
|
|
||||||
- MYSQL_DATABASE=photoview
|
|
||||||
- MYSQL_USER=photoview
|
|
||||||
- MYSQL_PASSWORD=photosecret
|
|
||||||
- MYSQL_RANDOM_ROOT_PASSWORD=1
|
|
||||||
volumes:
|
|
||||||
- photoview_db_data:/var/lib/mysql
|
|
||||||
networks:
|
|
||||||
- photo-backend
|
|
||||||
|
|
||||||
photoview:
|
|
||||||
container_name: photoview
|
|
||||||
image: viktorstrate/photoview:2
|
|
||||||
restart: unless-stopped
|
|
||||||
expose:
|
|
||||||
- 80
|
|
||||||
depends_on:
|
|
||||||
- photoview-db
|
|
||||||
networks:
|
|
||||||
- photo-backend
|
|
||||||
- photo-frontend
|
|
||||||
environment:
|
|
||||||
- PHOTOVIEW_DATABASE_DRIVER=mysql
|
|
||||||
- PHOTOVIEW_MYSQL_URL=photoview:photosecret@tcp(photoview-db)/photoview
|
|
||||||
- PHOTOVIEW_LISTEN_IP=photoview
|
|
||||||
- PHOTOVIEW_LISTEN_PORT=80
|
|
||||||
- PHOTOVIEW_MEDIA_CACHE=/app/cache
|
|
||||||
|
|
||||||
# Optional: If you are using Samba/CIFS-Share and experience problems with "directory not found"
|
|
||||||
# Enable the following Godebug
|
|
||||||
# - GODEBUG=asyncpreemptoff=1
|
|
||||||
|
|
||||||
|
|
||||||
# Optional: To enable map related features, you need to create a mapbox token.
|
|
||||||
# A token can be generated for free here https://account.mapbox.com/access-tokens/
|
|
||||||
# It's a good idea to limit the scope of the token to your own domain, to prevent others from using it.
|
|
||||||
- MAPBOX_TOKEN=${MAPBOX_TOKEN}
|
|
||||||
|
|
||||||
volumes:
|
|
||||||
- photoview_api_cache:/app/cache
|
|
||||||
|
|
||||||
# Change This: to the directory where your photos are located on your server.
|
|
||||||
# If the photos are located at `/home/user/photos`, then change this value
|
|
||||||
# to the following: `/home/user/photos:/photos:ro`.
|
|
||||||
# You can mount multiple paths, if your photos are spread across multiple directories.
|
|
||||||
#- ./photos_path:/photos:ro
|
|
||||||
- type: bind
|
|
||||||
source: ${ROOT_INSTALL}/data/seafile-fuse
|
|
||||||
target: /photos
|
|
||||||
bind:
|
|
||||||
propagation: rslave
|
|
||||||
privileged: true
|
|
||||||
cap_add:
|
|
||||||
- SYS_ADMIN
|
|
||||||
labels:
|
|
||||||
- traefik.enable=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
|
|
||||||
|
|
||||||
networks:
|
|
||||||
photo-frontend:
|
|
||||||
name: photo-frontend
|
|
||||||
photo-backend:
|
|
||||||
name: photo-backend
|
|
||||||
|
|
||||||
volumes:
|
|
||||||
photoview_db_data:
|
|
||||||
photoview_api_cache:
|
|
|
@ -1,45 +0,0 @@
|
||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
|
||||||
pigallery2:
|
|
||||||
container_name: pigallery2
|
|
||||||
environment:
|
|
||||||
NODE_ENV: production
|
|
||||||
image: bpatrik/pigallery2:1.9.0-alpine
|
|
||||||
networks:
|
|
||||||
- photo-frontend
|
|
||||||
expose:
|
|
||||||
- 80
|
|
||||||
restart: unless-stopped
|
|
||||||
volumes:
|
|
||||||
#/app/data/images
|
|
||||||
- pigallery_config:/app/data/config:rw
|
|
||||||
- pigallerydb_data:/app/data/db:rw
|
|
||||||
- pigallery_tmp:/app/data/tmp:rw
|
|
||||||
- type: bind
|
|
||||||
source: ${ROOT_INSTALL}/data/seafile-fuse
|
|
||||||
target: /seahub
|
|
||||||
bind:
|
|
||||||
propagation: rslave
|
|
||||||
privileged: true
|
|
||||||
cap_add:
|
|
||||||
- SYS_ADMIN
|
|
||||||
healthcheck:
|
|
||||||
disable: true
|
|
||||||
labels:
|
|
||||||
- traefik.enable=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
|
|
||||||
|
|
||||||
networks:
|
|
||||||
photo-frontend:
|
|
||||||
name: photo-frontend
|
|
||||||
photo-backend:
|
|
||||||
name: photo-backend
|
|
||||||
|
|
||||||
volumes:
|
|
||||||
pigallerydb_data:
|
|
||||||
pigallery_tmp:
|
|
||||||
pigallery_config:
|
|
|
@ -1,32 +0,0 @@
|
||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
|
||||||
poste-io:
|
|
||||||
container_name: poste-io
|
|
||||||
image: analogic/poste.io
|
|
||||||
volumes:
|
|
||||||
- ${ROOT_INSTALL}/data/poste.io:/data
|
|
||||||
environment:
|
|
||||||
- TZ=${TZ}
|
|
||||||
- HTTPS=OFF
|
|
||||||
restart: unless-stopped
|
|
||||||
ports:
|
|
||||||
- "465:465"
|
|
||||||
- "993:993"
|
|
||||||
- "25:25"
|
|
||||||
expose:
|
|
||||||
- 80
|
|
||||||
labels:
|
|
||||||
- traefik.enable=true
|
|
||||||
- traefik.http.routers.posteio.rule=Host(`${HOST_MAIL}.${DOMAIN}`)
|
|
||||||
- traefik.http.routers.posteio.entrypoints=https
|
|
||||||
- traefik.http.routers.posteio.tls=true
|
|
||||||
- traefik.docker.network=posteio-frontend
|
|
||||||
networks:
|
|
||||||
- posteio-frontend
|
|
||||||
healthcheck:
|
|
||||||
disable: true
|
|
||||||
|
|
||||||
networks:
|
|
||||||
posteio-frontend:
|
|
||||||
name: portainer-frontend
|
|
|
@ -1,68 +0,0 @@
|
||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
|
||||||
seafile-db:
|
|
||||||
container_name: seafile-db
|
|
||||||
environment:
|
|
||||||
MYSQL_LOG_CONSOLE: "true"
|
|
||||||
MYSQL_ROOT_PASSWORD: ${SEAFILE_DB_ROOT_PASSWORD}
|
|
||||||
image: mariadb:10.1
|
|
||||||
networks:
|
|
||||||
- seafile-backend
|
|
||||||
volumes:
|
|
||||||
- seafile_db:/var/lib/mysql:rw
|
|
||||||
restart: unless-stopped
|
|
||||||
seafile-memcached:
|
|
||||||
container_name: seafile-memcached
|
|
||||||
entrypoint: memcached -m 256
|
|
||||||
image: memcached:1.5.6
|
|
||||||
networks:
|
|
||||||
- seafile-backend
|
|
||||||
restart: unless-stopped
|
|
||||||
seafile:
|
|
||||||
container_name: seafile
|
|
||||||
depends_on:
|
|
||||||
- seafile-db
|
|
||||||
- seafile-memcached
|
|
||||||
environment:
|
|
||||||
DB_HOST: seafile-db
|
|
||||||
DB_ROOT_PASSWD: ${SEAFILE_DB_ROOT_PASSWORD}
|
|
||||||
SEAFILE_ADMIN_EMAIL: ${SEAFILE_ADMIN_EMAIL}
|
|
||||||
SEAFILE_ADMIN_PASSWORD: ${SEAFILE_ADMIN_PASSWORD}
|
|
||||||
SEAFILE_SERVER_HOSTNAME: ${HOST_SEAFILE}.${DOMAIN}
|
|
||||||
SEAFILE_SERVER_LETSENCRYPT: "false"
|
|
||||||
TIME_ZONE: ${TZ}
|
|
||||||
image: seafileltd/seafile-mc:latest
|
|
||||||
networks:
|
|
||||||
- seafile-backend
|
|
||||||
- seafile-frontend
|
|
||||||
restart: unless-stopped
|
|
||||||
expose:
|
|
||||||
- 80
|
|
||||||
volumes:
|
|
||||||
- ${ROOT_INSTALL}/selfhosting/seafile/start.py:/scripts/start.py
|
|
||||||
- seafile_data:/shared:rw
|
|
||||||
- type: bind
|
|
||||||
source: ${ROOT_INSTALL}/data/seafile-fuse
|
|
||||||
target: /seafile-fuse
|
|
||||||
bind:
|
|
||||||
propagation: rshared
|
|
||||||
privileged: true
|
|
||||||
cap_add:
|
|
||||||
- SYS_ADMIN
|
|
||||||
labels:
|
|
||||||
- traefik.enable=true
|
|
||||||
- traefik.http.routers.seafile.rule=Host(`${HOST_SEAFILE}.${DOMAIN}`)
|
|
||||||
- traefik.http.routers.seafile.entrypoints=https
|
|
||||||
- traefik.http.routers.seafile.tls=true
|
|
||||||
- traefik.docker.network=seafile-frontend
|
|
||||||
|
|
||||||
networks:
|
|
||||||
seafile-frontend:
|
|
||||||
name: seafile-frontend
|
|
||||||
seafile-backend:
|
|
||||||
name: seafile-backend
|
|
||||||
|
|
||||||
volumes:
|
|
||||||
seafile_db:
|
|
||||||
seafile_data:
|
|
|
@ -1,88 +0,0 @@
|
||||||
#!/usr/bin/env python3
|
|
||||||
#coding: UTF-8
|
|
||||||
|
|
||||||
"""
|
|
||||||
Starts the seafile/seahub server and watches the controller process. It is
|
|
||||||
the entrypoint command of the docker container.
|
|
||||||
"""
|
|
||||||
|
|
||||||
import json
|
|
||||||
import os
|
|
||||||
from os.path import abspath, basename, exists, dirname, join, isdir
|
|
||||||
import shutil
|
|
||||||
import sys
|
|
||||||
import time
|
|
||||||
|
|
||||||
from utils import (
|
|
||||||
call, get_conf, get_install_dir, get_script, get_command_output,
|
|
||||||
render_template, wait_for_mysql, setup_logging
|
|
||||||
)
|
|
||||||
from upgrade import check_upgrade
|
|
||||||
from bootstrap import init_seafile_server, is_https, init_letsencrypt, generate_local_nginx_conf
|
|
||||||
|
|
||||||
|
|
||||||
shared_seafiledir = '/shared/seafile'
|
|
||||||
ssl_dir = '/shared/ssl'
|
|
||||||
generated_dir = '/bootstrap/generated'
|
|
||||||
installdir = get_install_dir()
|
|
||||||
topdir = dirname(installdir)
|
|
||||||
|
|
||||||
def watch_controller():
|
|
||||||
maxretry = 4
|
|
||||||
retry = 0
|
|
||||||
while retry < maxretry:
|
|
||||||
controller_pid = get_command_output('ps aux | grep seafile-controller | grep -v grep || true').strip()
|
|
||||||
garbage_collector_pid = get_command_output('ps aux | grep /scripts/gc.sh | grep -v grep || true').strip()
|
|
||||||
if not controller_pid and not garbage_collector_pid:
|
|
||||||
retry += 1
|
|
||||||
else:
|
|
||||||
retry = 0
|
|
||||||
time.sleep(5)
|
|
||||||
print('seafile controller exited unexpectedly.')
|
|
||||||
sys.exit(1)
|
|
||||||
|
|
||||||
def main():
|
|
||||||
if not exists(shared_seafiledir):
|
|
||||||
os.mkdir(shared_seafiledir)
|
|
||||||
if not exists(generated_dir):
|
|
||||||
os.makedirs(generated_dir)
|
|
||||||
|
|
||||||
if is_https():
|
|
||||||
init_letsencrypt()
|
|
||||||
generate_local_nginx_conf()
|
|
||||||
call('nginx -s reload')
|
|
||||||
|
|
||||||
wait_for_mysql()
|
|
||||||
init_seafile_server()
|
|
||||||
|
|
||||||
check_upgrade()
|
|
||||||
os.chdir(installdir)
|
|
||||||
|
|
||||||
admin_pw = {
|
|
||||||
'email': get_conf('SEAFILE_ADMIN_EMAIL', 'me@example.com'),
|
|
||||||
'password': get_conf('SEAFILE_ADMIN_PASSWORD', 'asecret'),
|
|
||||||
}
|
|
||||||
password_file = join(topdir, 'conf', 'admin.txt')
|
|
||||||
with open(password_file, 'w') as fp:
|
|
||||||
json.dump(admin_pw, fp)
|
|
||||||
|
|
||||||
|
|
||||||
try:
|
|
||||||
call('{} start'.format(get_script('seafile.sh')))
|
|
||||||
call('{} start'.format(get_script('seahub.sh')))
|
|
||||||
call('{} start /seafile-fuse'.format(get_script('seaf-fuse.sh')))
|
|
||||||
finally:
|
|
||||||
if exists(password_file):
|
|
||||||
os.unlink(password_file)
|
|
||||||
|
|
||||||
print('seafile server is running now.')
|
|
||||||
try:
|
|
||||||
watch_controller()
|
|
||||||
except KeyboardInterrupt:
|
|
||||||
print('Stopping seafile server.')
|
|
||||||
sys.exit(0)
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
|
||||||
setup_logging()
|
|
||||||
main()
|
|
||||||
|
|
|
@ -42,16 +42,9 @@ services:
|
||||||
- 443:443
|
- 443:443
|
||||||
networks:
|
networks:
|
||||||
- dmz
|
- dmz
|
||||||
- baikal-frontend
|
|
||||||
- blog-frontend
|
- blog-frontend
|
||||||
- deluge-frontend
|
|
||||||
- dokuwiki-frontend
|
|
||||||
- glances-frontend
|
- glances-frontend
|
||||||
- netdata-frontend
|
|
||||||
- photo-frontend
|
|
||||||
- portainer-frontend
|
- portainer-frontend
|
||||||
- posteio-frontend
|
|
||||||
- seafile-frontend
|
|
||||||
- selfoss-frontend
|
- selfoss-frontend
|
||||||
- shaarli-frontend
|
- shaarli-frontend
|
||||||
- source-frontend
|
- source-frontend
|
||||||
|
|
|
@ -15,16 +15,9 @@ services:
|
||||||
- traefik.enable=true
|
- traefik.enable=true
|
||||||
networks:
|
networks:
|
||||||
- dmz
|
- dmz
|
||||||
- baikal-frontend
|
|
||||||
- blog-frontend
|
- blog-frontend
|
||||||
- deluge-frontend
|
|
||||||
- dokuwiki-frontend
|
|
||||||
- glances-frontend
|
- glances-frontend
|
||||||
- netdata-frontend
|
|
||||||
- photo-frontend
|
|
||||||
- portainer-frontend
|
- portainer-frontend
|
||||||
- posteio-frontend
|
|
||||||
- seafile-frontend
|
|
||||||
- selfoss-frontend
|
- selfoss-frontend
|
||||||
- shaarli-frontend
|
- shaarli-frontend
|
||||||
- source-frontend
|
- source-frontend
|
||||||
|
|
|
@ -1,40 +0,0 @@
|
||||||
version: '3.8'
|
|
||||||
|
|
||||||
services:
|
|
||||||
dashy:
|
|
||||||
# To build from source, replace 'image: lissy93/dashy' with 'build: .'
|
|
||||||
# build: .
|
|
||||||
image: lissy93/dashy
|
|
||||||
container_name: dashy
|
|
||||||
# Pass in your config file below, by specifying the path on your host machine
|
|
||||||
volumes:
|
|
||||||
- ${ROOT_INSTALL}/data/dashy/config.yml:/app/public/conf.yml
|
|
||||||
# Set any environmental variables
|
|
||||||
environment:
|
|
||||||
- NODE_ENV=production
|
|
||||||
# Specify your user ID and group ID. You can find this by running `id -u` and `id -g`
|
|
||||||
# - UID=1000
|
|
||||||
# - GID=1000
|
|
||||||
# Specify restart policy
|
|
||||||
restart: unless-stopped
|
|
||||||
# Configure healthchecks
|
|
||||||
#healthcheck:
|
|
||||||
# test: ['CMD', 'node', '/app/services/healthcheck']
|
|
||||||
# interval: 1m30s
|
|
||||||
# timeout: 10s
|
|
||||||
# retries: 3
|
|
||||||
# start_period: 40s
|
|
||||||
networks:
|
|
||||||
- wwww-frontend
|
|
||||||
expose:
|
|
||||||
- 80
|
|
||||||
labels:
|
|
||||||
- traefik.enable=true
|
|
||||||
- traefik.http.routers.dashy.rule=Host(`${FQDN_DASHBOARD}`)
|
|
||||||
- traefik.http.routers.dashy.entrypoints=https
|
|
||||||
- traefik.http.routers.dashy.tls=true
|
|
||||||
- traefik.docker.network=wwww-frontend
|
|
||||||
|
|
||||||
networks:
|
|
||||||
wwww-frontend:
|
|
||||||
name: wwww-frontend
|
|
Loading…
Add table
Reference in a new issue