From 3b4c3cb54ca96c0f22168784f72095c6ed6c1855 Mon Sep 17 00:00:00 2001 From: Bensuperpc Date: Sun, 19 Jan 2025 21:08:53 +0100 Subject: [PATCH] Improve docker-compose Signed-off-by: Bensuperpc --- DockerCompose.mk | 2 +- README.md | 38 ++++----- infrastructure/docker-compose.yml | 73 ++++++++++++++++++ infrastructure/main/docker-compose.main.yml | 34 -------- .../{ => services}/caddy/config/Caddyfile | 0 .../caddy/config/bensuperpc.com/Caddyfile | 0 .../caddy/config/bensuperpc.fr/Caddyfile | 0 .../caddy/config/bensuperpc.net/Caddyfile | 0 .../caddy/config/bensuperpc.org/Caddyfile | 0 .../caddy/config/bensuperpc.ovh/Caddyfile | 0 .../caddy/docker-compose.caddy.yml | 6 +- .../{ => services}/caddy/env/caddy.env | 0 .../{ => services}/caddy/env/caddy_backup.env | 0 .../dufs/docker-compose.dufs.yml | 2 +- .../{ => services}/dufs/env/dufs.env | 0 .../gitea/config/gitea_runner/config.yaml | 0 .../gitea/docker-compose.gitea.yml | 8 +- .../{ => services}/gitea/env/gitea-runner.env | 0 .../{ => services}/gitea/env/gitea.env | 0 .../{ => services}/gitea/env/gitea_db.env | 0 .../homepage/config/bookmarks.yaml | 0 .../{ => services}/homepage/config/custom.css | 0 .../{ => services}/homepage/config/custom.js | 0 .../homepage/config/docker.yaml | 0 .../homepage/config/kubernetes.yaml | 0 .../homepage/config/services.yaml | 0 .../homepage/config/settings.yaml | 0 .../homepage/config/widgets.yaml | 0 .../homepage/docker-compose.homepage.yml | 6 +- .../{ => services}/homepage/env/homepage.env | 0 .../homepage/image/background.jpg | Bin .../{ => services}/homepage/image/daisy.jpg | Bin .../{ => services}/homepage/image/favicon.ico | Bin .../it-tools/docker-compose.it-tools.yml | 0 .../jellyfin/docker-compose.jellyfin.yml | 2 +- .../{ => services}/jellyfin/env/jellyfin.env | 0 .../config/authorized_keys/id_ed25519.pub | 0 .../openssh/docker-compose.openssh.yml | 4 +- .../{ => services}/openssh/env/openssh.env | 0 .../picoshare/docker-compose.picoshare.yml | 2 +- .../picoshare/env/picoshare.env | 0 .../{ => services}/privatebin/config/conf.php | 0 .../privatebin/docker-compose.privatebin.yml | 2 +- .../docker-compose.projectsend.yml | 4 +- .../projectsend/env/projectsend.env | 0 .../projectsend/env/projectsend_db.env | 0 .../docker-compose.psitransfer.yml | 2 +- .../psitransfer/env/psitransfer.env | 0 .../docker-compose.qbittorrent.yml | 2 +- .../qbittorrent/env/qbittorrent.env | 0 .../docker-compose.stirlingpdf.yml | 2 +- .../stirlingpdf/env/stirlingpdf.env | 0 .../syncthing/docker-compose.syncthing.yml | 2 +- .../syncthing/env/syncthing.env | 0 .../docker-compose.transmission.yml | 2 +- .../transmission/env/transmission.env | 0 .../docker-compose.uptime-kuma.yml | 0 .../wordpress/config/wordpress/php.ini | 0 .../wordpress/docker-compose.adminer.yml | 2 +- .../wordpress/docker-compose.wordpress.yml | 8 +- .../{ => services}/wordpress/env/adminer.env | 0 .../wordpress/env/wordpress.env | 0 .../wordpress/env/wordpress_backup.env | 0 .../wordpress/env/wordpress_db.env | 0 .../yacht/docker-compose.yacht.yml | 2 +- .../{ => services}/yacht/env/yacht.env | 0 66 files changed, 122 insertions(+), 83 deletions(-) create mode 100644 infrastructure/docker-compose.yml delete mode 100644 infrastructure/main/docker-compose.main.yml rename infrastructure/{ => services}/caddy/config/Caddyfile (100%) rename infrastructure/{ => services}/caddy/config/bensuperpc.com/Caddyfile (100%) rename infrastructure/{ => services}/caddy/config/bensuperpc.fr/Caddyfile (100%) rename infrastructure/{ => services}/caddy/config/bensuperpc.net/Caddyfile (100%) rename infrastructure/{ => services}/caddy/config/bensuperpc.org/Caddyfile (100%) rename infrastructure/{ => services}/caddy/config/bensuperpc.ovh/Caddyfile (100%) rename infrastructure/{ => services}/caddy/docker-compose.caddy.yml (91%) rename infrastructure/{ => services}/caddy/env/caddy.env (100%) rename infrastructure/{ => services}/caddy/env/caddy_backup.env (100%) rename infrastructure/{ => services}/dufs/docker-compose.dufs.yml (93%) rename infrastructure/{ => services}/dufs/env/dufs.env (100%) rename infrastructure/{ => services}/gitea/config/gitea_runner/config.yaml (100%) rename infrastructure/{ => services}/gitea/docker-compose.gitea.yml (89%) rename infrastructure/{ => services}/gitea/env/gitea-runner.env (100%) rename infrastructure/{ => services}/gitea/env/gitea.env (100%) rename infrastructure/{ => services}/gitea/env/gitea_db.env (100%) rename infrastructure/{ => services}/homepage/config/bookmarks.yaml (100%) rename infrastructure/{ => services}/homepage/config/custom.css (100%) rename infrastructure/{ => services}/homepage/config/custom.js (100%) rename infrastructure/{ => services}/homepage/config/docker.yaml (100%) rename infrastructure/{ => services}/homepage/config/kubernetes.yaml (100%) rename infrastructure/{ => services}/homepage/config/services.yaml (100%) rename infrastructure/{ => services}/homepage/config/settings.yaml (100%) rename infrastructure/{ => services}/homepage/config/widgets.yaml (100%) rename infrastructure/{ => services}/homepage/docker-compose.homepage.yml (82%) rename infrastructure/{ => services}/homepage/env/homepage.env (100%) rename infrastructure/{ => services}/homepage/image/background.jpg (100%) rename infrastructure/{ => services}/homepage/image/daisy.jpg (100%) rename infrastructure/{ => services}/homepage/image/favicon.ico (100%) rename infrastructure/{ => services}/it-tools/docker-compose.it-tools.yml (100%) rename infrastructure/{ => services}/jellyfin/docker-compose.jellyfin.yml (95%) rename infrastructure/{ => services}/jellyfin/env/jellyfin.env (100%) rename infrastructure/{ => services}/openssh/config/authorized_keys/id_ed25519.pub (100%) rename infrastructure/{ => services}/openssh/docker-compose.openssh.yml (89%) rename infrastructure/{ => services}/openssh/env/openssh.env (100%) rename infrastructure/{ => services}/picoshare/docker-compose.picoshare.yml (94%) rename infrastructure/{ => services}/picoshare/env/picoshare.env (100%) rename infrastructure/{ => services}/privatebin/config/conf.php (100%) rename infrastructure/{ => services}/privatebin/docker-compose.privatebin.yml (90%) rename infrastructure/{ => services}/projectsend/docker-compose.projectsend.yml (92%) rename infrastructure/{ => services}/projectsend/env/projectsend.env (100%) rename infrastructure/{ => services}/projectsend/env/projectsend_db.env (100%) rename infrastructure/{ => services}/psitransfer/docker-compose.psitransfer.yml (93%) rename infrastructure/{ => services}/psitransfer/env/psitransfer.env (100%) rename infrastructure/{ => services}/qbittorrent/docker-compose.qbittorrent.yml (93%) rename infrastructure/{ => services}/qbittorrent/env/qbittorrent.env (100%) rename infrastructure/{ => services}/stirlingpdf/docker-compose.stirlingpdf.yml (92%) rename infrastructure/{ => services}/stirlingpdf/env/stirlingpdf.env (100%) rename infrastructure/{ => services}/syncthing/docker-compose.syncthing.yml (94%) rename infrastructure/{ => services}/syncthing/env/syncthing.env (100%) rename infrastructure/{ => services}/transmission/docker-compose.transmission.yml (94%) rename infrastructure/{ => services}/transmission/env/transmission.env (100%) rename infrastructure/{ => services}/uptime-kuma/docker-compose.uptime-kuma.yml (100%) rename infrastructure/{ => services}/wordpress/config/wordpress/php.ini (100%) rename infrastructure/{ => services}/wordpress/docker-compose.adminer.yml (89%) rename infrastructure/{ => services}/wordpress/docker-compose.wordpress.yml (86%) rename infrastructure/{ => services}/wordpress/env/adminer.env (100%) rename infrastructure/{ => services}/wordpress/env/wordpress.env (100%) rename infrastructure/{ => services}/wordpress/env/wordpress_backup.env (100%) rename infrastructure/{ => services}/wordpress/env/wordpress_db.env (100%) rename infrastructure/{ => services}/yacht/docker-compose.yacht.yml (93%) rename infrastructure/{ => services}/yacht/env/yacht.env (100%) diff --git a/DockerCompose.mk b/DockerCompose.mk index 40cf766..6daaaf1 100644 --- a/DockerCompose.mk +++ b/DockerCompose.mk @@ -19,7 +19,7 @@ DOCKER_PROFILES ?= main_infrastructure PROFILE_CMD ?= $(addprefix --profile ,$(DOCKER_PROFILES)) -COMPOSE_FILES ?= $(shell find ./$(PROJECT_DIRECTORY) -name 'docker-compose*.yml' -type f | sed -e 's/^/--file /') +COMPOSE_FILES ?= $(shell find ./$(PROJECT_DIRECTORY) -maxdepth 1 -name 'docker-compose*.yml' -type f | sed -e 's/^/--file /') COMPOSE_DIR ?= --project-directory ./$(PROJECT_DIRECTORY) UID ?= 1000 diff --git a/README.md b/README.md index 9d1d6dd..c887b24 100644 --- a/README.md +++ b/README.md @@ -68,7 +68,7 @@ For all **bensuperpc.org**, you need to replace it with your domain, example: ** find . \( -type d -name .git -prune \) -o -type f -print0 | xargs -0 sed -i 's/bensuperpc.org/mydomain.com/g' ``` -Check if all bensuperpc.* are replaced by your domain in [Caddyfile](caddy/wordpress/Caddyfile) +Check if all bensuperpc.* are replaced by your domain in [Caddyfile](caddy/services/wordpress/Caddyfile) And then, caddy will generate the certificate for you and renew it automatically :D @@ -110,19 +110,19 @@ openssl rand -base64 32 Or online: [passwordsgenerator.net](https://passwordsgenerator.net/) -For [caddy_backup.env](infrastructure/caddy/env/caddy_backup.env) file, you need to change the password(s) for the restic backup. +For [caddy_backup.env](infrastructure/services/caddy/env/caddy_backup.env) file, you need to change the password(s) for the restic backup. ```sh RESTIC_PASSWORD=7L1Ncbquax0B2TCOmrjaQl9n5mnY88bQ ``` -For the [wordpress.env](infrastructure/wordpress/env/wordpress.env) file, you need to change the password and user for the database. +For the [wordpress.env](infrastructure/services/wordpress/env/wordpress.env) file, you need to change the password and user for the database. ```sh WORDPRESS_DB_USER=bensuperpc WORDPRESS_DB_PASSWORD=lEOEf8cndnDjp84O4Uv5D9zJLJDFatLw ``` -For [wordpress_db.env](infrastructure/wordpress/env/wordpress_db.env) file, you need to change the password(s) and user for the database. +For [wordpress_db.env](infrastructure/services/wordpress/env/wordpress_db.env) file, you need to change the password(s) and user for the database. ```sh MARIADB_ROOT_PASSWORD=7L1Ncbquax0B2TCOmrjaQl9n5mnY88bQ @@ -130,12 +130,12 @@ MARIADB_USER=bensuperpc MARIADB_PASSWORD=lEOEf8cndnDjp84O4Uv5D9zJLJDFatLw ``` -For [wordpress_backup.env](infrastructure/wordpress/env/wordpress_backup.env) file, you need to change the password(s) for the restic backup. +For [wordpress_backup.env](infrastructure/services/wordpress/env/wordpress_backup.env) file, you need to change the password(s) for the restic backup. ```sh RESTIC_PASSWORD=7L1Ncbquax0B2TCOmrjaQl9n5mnY88bQ ``` -For [adminer.env](infrastructure/wordpress/env/adminer.env) file, you need to change the password(s) and user for the database. +For [adminer.env](infrastructure/services/wordpress/env/adminer.env) file, you need to change the password(s) and user for the database. ```sh MARIADB_ROOT_PASSWORD=7L1Ncbquax0B2TCOmrjaQl9n5mnY88bQ @@ -143,7 +143,7 @@ MARIADB_USER=bensuperpc MARIADB_PASSWORD=lEOEf8cndnDjp84O4Uv5D9zJLJDFatLw ``` -For [gitea.env](infrastructure/gitea/env/gitea.env) file, you need to change the password(s) and user for the database. +For [gitea.env](infrastructure/services/gitea/env/gitea.env) file, you need to change the password(s) and user for the database. ```sh GITEA__database__USER=bensuperpc @@ -151,7 +151,7 @@ GITEA__database__PASSWD=K7s5yoHknnEd7vsZoxb8I3dK9mjToF1j GITEA__security__SECRET_KEY=ykcZt23an1E4lFHWvrCKdAyt16WAiK9c ``` -For [gitea_db.env](infrastructure/gitea/env/gitea_db.env) file, you need to change the password(s) and user for the database. +For [gitea_db.env](infrastructure/services/gitea/env/gitea_db.env) file, you need to change the password(s) and user for the database. ```sh MARIADB_ROOT_PASSWORD=xpc4zIhHZzWKqVHcjBu4aW6aS7jG8d7X @@ -159,19 +159,19 @@ MARIADB_USER=bensuperpc MARIADB_PASSWORD=K7s5yoHknnEd7vsZoxb8I3dK9mjToF1j ``` -For [psitransfer.env](infrastructure/psitransfer/env/psitransfer.env) file, you need to change the secret key. +For [psitransfer.env](infrastructure/services/psitransfer/env/psitransfer.env) file, you need to change the secret key. ```sh PSITRANSFER_ADMIN_PASS=n9jLVNT9QUotTJTT91JqH4GyBTg9pvEn ``` -For [yacht.env](infrastructure/yacht/env/yacht.env) file, you need to change the secret key. +For [yacht.env](infrastructure/services/yacht/env/yacht.env) file, you need to change the secret key. ```sh SECRET_KEY=UZvg9nbcGIJlPEB3uI39TAEWyFOz9nm8 ``` -For [projectsend_db.env](infrastructure/projectsend/env/projectsend_db.env) file, you need to change the password(s) and user for the database. +For [projectsend_db.env](infrastructure/services/projectsend/env/projectsend_db.env) file, you need to change the password(s) and user for the database. ```sh MARIADB_ROOT_PASSWORD=8O34297GrBfT3Ld34Lfg9mpotmZwbJtt @@ -179,19 +179,19 @@ MARIADB_USER=bensuperpc MARIADB_PASSWORD=wdSUa1JEZhXie5AJ5NcX1w73xmpO12EY ``` -For [picoshare.env](infrastructure/picoshare/env/picoshare.env) file, you need to change the secret key. +For [picoshare.env](infrastructure/services/picoshare/env/picoshare.env) file, you need to change the secret key. ```sh PS_SHARED_SECRET=CBuS4DJLqIe93xF1KGYRrnhxUFBqLD2n ``` -For [dufs.env](infrastructure/dufs/env/dufs.env) file, you need to change the secret key and if you want the user name. +For [dufs.env](infrastructure/services/dufs/env/dufs.env) file, you need to change the secret key and if you want the user name. ```sh DUFS_AUTH="admin:heqihlOfBmJDESGFlpbPi7P7Mi6F7RkV@/:rw|@/:ro" ``` -For [stirlingpdf.env](infrastructure/stirlingpdf/env/stirlingpdf.env) file, it's **completly optional**, you can change the password(s) and user. +For [stirlingpdf.env](infrastructure/services/stirlingpdf/env/stirlingpdf.env) file, it's **completly optional**, you can change the password(s) and user. ```sh # Enable security, optional @@ -203,7 +203,7 @@ SECURITY_INITIALLOGIN_USERNAME=admin SECURITY_INITIALLOGIN_PASSWORD=Jw9U039f5xc2mFcacvGvPD9RjwIh4DzO ``` -You can need to add/change the public ssh key [id_ed25519.pub](infrastructure/openssh/config/authorized_keys/id_ed25519.pub) (its my public key), also change the config/password in [openssh.env](infrastructure/openssh/env/openssh.env): +You can need to add/change the public ssh key [id_ed25519.pub](infrastructure/services/openssh/config/authorized_keys/id_ed25519.pub) (its my public key), also change the config/password in [openssh.env](infrastructure/services/openssh/env/openssh.env): ```sh SUDO_ACCESS=true @@ -245,10 +245,10 @@ To enable the gitea CI: https://medium.com/@lokanx/how-to-build-docker-container You can change the homepage config in these files: -- [bookmarks.yaml](infrastructure/homepage/config/bookmarks.yaml) -- [services.yaml](infrastructure/homepage/config/services.yaml) -- [settings.yaml](infrastructure/homepage/config/settings.yaml) -- [widgets.yaml](infrastructure/homepage/config/widgets.yaml) +- [bookmarks.yaml](infrastructure/services/homepage/config/bookmarks.yaml) +- [services.yaml](infrastructure/services/homepage/config/services.yaml) +- [settings.yaml](infrastructure/services/homepage/config/settings.yaml) +- [widgets.yaml](infrastructure/services/homepage/config/widgets.yaml) ### Docker volumes diff --git a/infrastructure/docker-compose.yml b/infrastructure/docker-compose.yml new file mode 100644 index 0000000..f7c6696 --- /dev/null +++ b/infrastructure/docker-compose.yml @@ -0,0 +1,73 @@ +include: +# WordPress + - services/wordpress/docker-compose.adminer.yml + - services/wordpress/docker-compose.wordpress.yml +# Caddy + - services/caddy/docker-compose.caddy.yml +# Dufs + - services/dufs/docker-compose.dufs.yml +# Gitea + - services/gitea/docker-compose.gitea.yml +# Homepage + - services/homepage/docker-compose.homepage.yml +# It-tools + - services/it-tools/docker-compose.it-tools.yml +# Jellyfin + - services/jellyfin/docker-compose.jellyfin.yml +# Openssh + - services/openssh/docker-compose.openssh.yml +# Picoshare + - services/picoshare/docker-compose.picoshare.yml +# Privatebin + - services/privatebin/docker-compose.privatebin.yml +# Projectsend + - services/projectsend/docker-compose.projectsend.yml +# Psitransfer + - services/psitransfer/docker-compose.psitransfer.yml +# Qbittorrent + - services/qbittorrent/docker-compose.qbittorrent.yml +# Stirlingpdf + - services/stirlingpdf/docker-compose.stirlingpdf.yml +# Syncthing + - services/syncthing/docker-compose.syncthing.yml +# Transmission + - services/transmission/docker-compose.transmission.yml +# Uptime-kuma + - services/uptime-kuma/docker-compose.uptime-kuma.yml +# Yacht + - services/yacht/docker-compose.yacht.yml + +services: + main_infrastructure: + container_name: main_infrastructure + image: alpine:latest + profiles: + - main_infrastructure + volumes: + - public_data:/public_data:rw + - private_data:/private_data:rw + read_only: true + security_opt: + - no-new-privileges:true + cap_drop: + - ALL + cap_add: + - CHOWN + - DAC_OVERRIDE + # Fix root permissions on mounted volumes + command: chown -R ${PUID:-1000}:${PGID:-1000} /public_data /private_data + +volumes: + public_data: + name: public_data + private_data: + name: private_data + +networks: + infra-network: + driver: bridge + name: infra-network + intern-network: + driver: bridge + internal: true + name: intern-network diff --git a/infrastructure/main/docker-compose.main.yml b/infrastructure/main/docker-compose.main.yml deleted file mode 100644 index e6e893a..0000000 --- a/infrastructure/main/docker-compose.main.yml +++ /dev/null @@ -1,34 +0,0 @@ -services: - main_infrastructure: - container_name: main_infrastructure - image: alpine:latest - profiles: - - main_infrastructure - volumes: - - public_data:/public_data:rw - - private_data:/private_data:rw - read_only: true - security_opt: - - no-new-privileges:true - cap_drop: - - ALL - cap_add: - - CHOWN - - DAC_OVERRIDE - # Fix root permissions on mounted volumes - command: chown -R ${PUID:-1000}:${PGID:-1000} /public_data /private_data - -volumes: - public_data: - name: public_data - private_data: - name: private_data - -networks: - infra-network: - driver: bridge - name: infra-network - intern-network: - driver: bridge - internal: true - name: intern-network diff --git a/infrastructure/caddy/config/Caddyfile b/infrastructure/services/caddy/config/Caddyfile similarity index 100% rename from infrastructure/caddy/config/Caddyfile rename to infrastructure/services/caddy/config/Caddyfile diff --git a/infrastructure/caddy/config/bensuperpc.com/Caddyfile b/infrastructure/services/caddy/config/bensuperpc.com/Caddyfile similarity index 100% rename from infrastructure/caddy/config/bensuperpc.com/Caddyfile rename to infrastructure/services/caddy/config/bensuperpc.com/Caddyfile diff --git a/infrastructure/caddy/config/bensuperpc.fr/Caddyfile b/infrastructure/services/caddy/config/bensuperpc.fr/Caddyfile similarity index 100% rename from infrastructure/caddy/config/bensuperpc.fr/Caddyfile rename to infrastructure/services/caddy/config/bensuperpc.fr/Caddyfile diff --git a/infrastructure/caddy/config/bensuperpc.net/Caddyfile b/infrastructure/services/caddy/config/bensuperpc.net/Caddyfile similarity index 100% rename from infrastructure/caddy/config/bensuperpc.net/Caddyfile rename to infrastructure/services/caddy/config/bensuperpc.net/Caddyfile diff --git a/infrastructure/caddy/config/bensuperpc.org/Caddyfile b/infrastructure/services/caddy/config/bensuperpc.org/Caddyfile similarity index 100% rename from infrastructure/caddy/config/bensuperpc.org/Caddyfile rename to infrastructure/services/caddy/config/bensuperpc.org/Caddyfile diff --git a/infrastructure/caddy/config/bensuperpc.ovh/Caddyfile b/infrastructure/services/caddy/config/bensuperpc.ovh/Caddyfile similarity index 100% rename from infrastructure/caddy/config/bensuperpc.ovh/Caddyfile rename to infrastructure/services/caddy/config/bensuperpc.ovh/Caddyfile diff --git a/infrastructure/caddy/docker-compose.caddy.yml b/infrastructure/services/caddy/docker-compose.caddy.yml similarity index 91% rename from infrastructure/caddy/docker-compose.caddy.yml rename to infrastructure/services/caddy/docker-compose.caddy.yml index 046326b..0465cc8 100644 --- a/infrastructure/caddy/docker-compose.caddy.yml +++ b/infrastructure/services/caddy/docker-compose.caddy.yml @@ -15,14 +15,14 @@ services: volumes: - caddy_data:/data:rw - caddy_config:/config:rw - - ./caddy/config:/etc/caddy:ro + - ./config:/etc/caddy:ro - wordpress:/var/www/html:rw - public_data:/public_data:ro networks: - infra-network env_file: - - ./caddy/env/caddy.env + - ./env/caddy.env security_opt: - no-new-privileges:true healthcheck: @@ -40,7 +40,7 @@ services: - caddy restart: on-failure:5 env_file: - - ./caddy/env/caddy_backup.env + - ./env/caddy_backup.env volumes: - caddy_backup:/mnt/restic - caddy_data:/data:ro diff --git a/infrastructure/caddy/env/caddy.env b/infrastructure/services/caddy/env/caddy.env similarity index 100% rename from infrastructure/caddy/env/caddy.env rename to infrastructure/services/caddy/env/caddy.env diff --git a/infrastructure/caddy/env/caddy_backup.env b/infrastructure/services/caddy/env/caddy_backup.env similarity index 100% rename from infrastructure/caddy/env/caddy_backup.env rename to infrastructure/services/caddy/env/caddy_backup.env diff --git a/infrastructure/dufs/docker-compose.dufs.yml b/infrastructure/services/dufs/docker-compose.dufs.yml similarity index 93% rename from infrastructure/dufs/docker-compose.dufs.yml rename to infrastructure/services/dufs/docker-compose.dufs.yml index d8ea357..bda49e2 100644 --- a/infrastructure/dufs/docker-compose.dufs.yml +++ b/infrastructure/services/dufs/docker-compose.dufs.yml @@ -10,7 +10,7 @@ services: depends_on: - caddy env_file: - - ./dufs/env/dufs.env + - ./env/dufs.env volumes: - public_data:/data networks: diff --git a/infrastructure/dufs/env/dufs.env b/infrastructure/services/dufs/env/dufs.env similarity index 100% rename from infrastructure/dufs/env/dufs.env rename to infrastructure/services/dufs/env/dufs.env diff --git a/infrastructure/gitea/config/gitea_runner/config.yaml b/infrastructure/services/gitea/config/gitea_runner/config.yaml similarity index 100% rename from infrastructure/gitea/config/gitea_runner/config.yaml rename to infrastructure/services/gitea/config/gitea_runner/config.yaml diff --git a/infrastructure/gitea/docker-compose.gitea.yml b/infrastructure/services/gitea/docker-compose.gitea.yml similarity index 89% rename from infrastructure/gitea/docker-compose.gitea.yml rename to infrastructure/services/gitea/docker-compose.gitea.yml index c5a4ed2..d462692 100644 --- a/infrastructure/gitea/docker-compose.gitea.yml +++ b/infrastructure/services/gitea/docker-compose.gitea.yml @@ -12,7 +12,7 @@ services: ports: - "22:22" env_file: - - ./gitea/env/gitea.env + - ./env/gitea.env volumes: - gitea_data:/var/lib/gitea - gitea_config:/etc/gitea @@ -36,7 +36,7 @@ services: volumes: - gitea_db:/var/lib/mysql:rw env_file: - - ./gitea/env/gitea_db.env + - ./env/gitea_db.env command: '--default-authentication-plugin=mysql_native_password' networks: - infra-network @@ -53,11 +53,11 @@ services: - gitea restart: on-failure:5 env_file: - - ./gitea/env/gitea-runner.env + - ./env/gitea-runner.env volumes: - /var/run/docker.sock:/var/run/docker.sock - gitea_runner:/data - - ./gitea/config/gitea_runner/config.yaml:/config.yaml:ro + - ./config/gitea_runner/config.yaml:/config.yaml:ro networks: - infra-network security_opt: diff --git a/infrastructure/gitea/env/gitea-runner.env b/infrastructure/services/gitea/env/gitea-runner.env similarity index 100% rename from infrastructure/gitea/env/gitea-runner.env rename to infrastructure/services/gitea/env/gitea-runner.env diff --git a/infrastructure/gitea/env/gitea.env b/infrastructure/services/gitea/env/gitea.env similarity index 100% rename from infrastructure/gitea/env/gitea.env rename to infrastructure/services/gitea/env/gitea.env diff --git a/infrastructure/gitea/env/gitea_db.env b/infrastructure/services/gitea/env/gitea_db.env similarity index 100% rename from infrastructure/gitea/env/gitea_db.env rename to infrastructure/services/gitea/env/gitea_db.env diff --git a/infrastructure/homepage/config/bookmarks.yaml b/infrastructure/services/homepage/config/bookmarks.yaml similarity index 100% rename from infrastructure/homepage/config/bookmarks.yaml rename to infrastructure/services/homepage/config/bookmarks.yaml diff --git a/infrastructure/homepage/config/custom.css b/infrastructure/services/homepage/config/custom.css similarity index 100% rename from infrastructure/homepage/config/custom.css rename to infrastructure/services/homepage/config/custom.css diff --git a/infrastructure/homepage/config/custom.js b/infrastructure/services/homepage/config/custom.js similarity index 100% rename from infrastructure/homepage/config/custom.js rename to infrastructure/services/homepage/config/custom.js diff --git a/infrastructure/homepage/config/docker.yaml b/infrastructure/services/homepage/config/docker.yaml similarity index 100% rename from infrastructure/homepage/config/docker.yaml rename to infrastructure/services/homepage/config/docker.yaml diff --git a/infrastructure/homepage/config/kubernetes.yaml b/infrastructure/services/homepage/config/kubernetes.yaml similarity index 100% rename from infrastructure/homepage/config/kubernetes.yaml rename to infrastructure/services/homepage/config/kubernetes.yaml diff --git a/infrastructure/homepage/config/services.yaml b/infrastructure/services/homepage/config/services.yaml similarity index 100% rename from infrastructure/homepage/config/services.yaml rename to infrastructure/services/homepage/config/services.yaml diff --git a/infrastructure/homepage/config/settings.yaml b/infrastructure/services/homepage/config/settings.yaml similarity index 100% rename from infrastructure/homepage/config/settings.yaml rename to infrastructure/services/homepage/config/settings.yaml diff --git a/infrastructure/homepage/config/widgets.yaml b/infrastructure/services/homepage/config/widgets.yaml similarity index 100% rename from infrastructure/homepage/config/widgets.yaml rename to infrastructure/services/homepage/config/widgets.yaml diff --git a/infrastructure/homepage/docker-compose.homepage.yml b/infrastructure/services/homepage/docker-compose.homepage.yml similarity index 82% rename from infrastructure/homepage/docker-compose.homepage.yml rename to infrastructure/services/homepage/docker-compose.homepage.yml index 8bdceb9..abd04b9 100644 --- a/infrastructure/homepage/docker-compose.homepage.yml +++ b/infrastructure/services/homepage/docker-compose.homepage.yml @@ -9,11 +9,11 @@ services: depends_on: - caddy env_file: - - ./homepage/env/homepage.env + - ./env/homepage.env volumes: - homepage_log:/app/logs - - ./homepage/config:/app/config:ro - - ./homepage/image:/app/public/image:ro + - ./config:/app/config:ro + - ./image:/app/public/image:ro - /var/run/docker.sock:/var/run/docker.sock:ro # develop: # watch: diff --git a/infrastructure/homepage/env/homepage.env b/infrastructure/services/homepage/env/homepage.env similarity index 100% rename from infrastructure/homepage/env/homepage.env rename to infrastructure/services/homepage/env/homepage.env diff --git a/infrastructure/homepage/image/background.jpg b/infrastructure/services/homepage/image/background.jpg similarity index 100% rename from infrastructure/homepage/image/background.jpg rename to infrastructure/services/homepage/image/background.jpg diff --git a/infrastructure/homepage/image/daisy.jpg b/infrastructure/services/homepage/image/daisy.jpg similarity index 100% rename from infrastructure/homepage/image/daisy.jpg rename to infrastructure/services/homepage/image/daisy.jpg diff --git a/infrastructure/homepage/image/favicon.ico b/infrastructure/services/homepage/image/favicon.ico similarity index 100% rename from infrastructure/homepage/image/favicon.ico rename to infrastructure/services/homepage/image/favicon.ico diff --git a/infrastructure/it-tools/docker-compose.it-tools.yml b/infrastructure/services/it-tools/docker-compose.it-tools.yml similarity index 100% rename from infrastructure/it-tools/docker-compose.it-tools.yml rename to infrastructure/services/it-tools/docker-compose.it-tools.yml diff --git a/infrastructure/jellyfin/docker-compose.jellyfin.yml b/infrastructure/services/jellyfin/docker-compose.jellyfin.yml similarity index 95% rename from infrastructure/jellyfin/docker-compose.jellyfin.yml rename to infrastructure/services/jellyfin/docker-compose.jellyfin.yml index aafe524..d57c8f6 100644 --- a/infrastructure/jellyfin/docker-compose.jellyfin.yml +++ b/infrastructure/services/jellyfin/docker-compose.jellyfin.yml @@ -12,7 +12,7 @@ services: depends_on: - caddy env_file: - - ./jellyfin/env/jellyfin.env + - ./env/jellyfin.env volumes: - jellyfin_config:/config - jellyfin_cache:/cache diff --git a/infrastructure/jellyfin/env/jellyfin.env b/infrastructure/services/jellyfin/env/jellyfin.env similarity index 100% rename from infrastructure/jellyfin/env/jellyfin.env rename to infrastructure/services/jellyfin/env/jellyfin.env diff --git a/infrastructure/openssh/config/authorized_keys/id_ed25519.pub b/infrastructure/services/openssh/config/authorized_keys/id_ed25519.pub similarity index 100% rename from infrastructure/openssh/config/authorized_keys/id_ed25519.pub rename to infrastructure/services/openssh/config/authorized_keys/id_ed25519.pub diff --git a/infrastructure/openssh/docker-compose.openssh.yml b/infrastructure/services/openssh/docker-compose.openssh.yml similarity index 89% rename from infrastructure/openssh/docker-compose.openssh.yml rename to infrastructure/services/openssh/docker-compose.openssh.yml index fafb238..d92b4b6 100644 --- a/infrastructure/openssh/docker-compose.openssh.yml +++ b/infrastructure/services/openssh/docker-compose.openssh.yml @@ -9,13 +9,13 @@ services: - caddy restart: on-failure:5 env_file: - - ./openssh/env/openssh.env + - ./env/openssh.env environment: - PUID=${PUID:-1000} - PGID=${PGID:-1000} volumes: - openssh_config:/config:rw - - ./openssh/config/authorized_keys:/authorized_ssh_keys:ro + - ./config/authorized_keys:/authorized_ssh_keys:ro - public_data:/public:rw - private_data:/private:rw - caddy_data:/caddy_data:rw diff --git a/infrastructure/openssh/env/openssh.env b/infrastructure/services/openssh/env/openssh.env similarity index 100% rename from infrastructure/openssh/env/openssh.env rename to infrastructure/services/openssh/env/openssh.env diff --git a/infrastructure/picoshare/docker-compose.picoshare.yml b/infrastructure/services/picoshare/docker-compose.picoshare.yml similarity index 94% rename from infrastructure/picoshare/docker-compose.picoshare.yml rename to infrastructure/services/picoshare/docker-compose.picoshare.yml index 617f117..2d19b6e 100644 --- a/infrastructure/picoshare/docker-compose.picoshare.yml +++ b/infrastructure/services/picoshare/docker-compose.picoshare.yml @@ -9,7 +9,7 @@ services: depends_on: - caddy env_file: - - ./picoshare/env/picoshare.env + - ./env/picoshare.env volumes: - picoshare_data:/data networks: diff --git a/infrastructure/picoshare/env/picoshare.env b/infrastructure/services/picoshare/env/picoshare.env similarity index 100% rename from infrastructure/picoshare/env/picoshare.env rename to infrastructure/services/picoshare/env/picoshare.env diff --git a/infrastructure/privatebin/config/conf.php b/infrastructure/services/privatebin/config/conf.php similarity index 100% rename from infrastructure/privatebin/config/conf.php rename to infrastructure/services/privatebin/config/conf.php diff --git a/infrastructure/privatebin/docker-compose.privatebin.yml b/infrastructure/services/privatebin/docker-compose.privatebin.yml similarity index 90% rename from infrastructure/privatebin/docker-compose.privatebin.yml rename to infrastructure/services/privatebin/docker-compose.privatebin.yml index 48e0b98..0779c3c 100644 --- a/infrastructure/privatebin/docker-compose.privatebin.yml +++ b/infrastructure/services/privatebin/docker-compose.privatebin.yml @@ -10,7 +10,7 @@ services: - caddy volumes: - privatebin_data:/srv/data - - ./privatebin/config/conf.php:/srv/cfg/conf.php:ro + - ./config/conf.php:/srv/cfg/conf.php:ro networks: - infra-network security_opt: diff --git a/infrastructure/projectsend/docker-compose.projectsend.yml b/infrastructure/services/projectsend/docker-compose.projectsend.yml similarity index 92% rename from infrastructure/projectsend/docker-compose.projectsend.yml rename to infrastructure/services/projectsend/docker-compose.projectsend.yml index bda7059..8f368dd 100644 --- a/infrastructure/projectsend/docker-compose.projectsend.yml +++ b/infrastructure/services/projectsend/docker-compose.projectsend.yml @@ -9,7 +9,7 @@ services: depends_on: - caddy env_file: - - ./projectsend/env/projectsend.env + - ./env/projectsend.env volumes: - /var/run/docker.sock:/var/run/docker.sock - projectsend_config:/config @@ -34,7 +34,7 @@ services: volumes: - projectsend_db:/var/lib/mysql:rw env_file: - - ./projectsend/env/projectsend_db.env + - ./env/projectsend_db.env command: '--default-authentication-plugin=mysql_native_password' networks: - infra-network diff --git a/infrastructure/projectsend/env/projectsend.env b/infrastructure/services/projectsend/env/projectsend.env similarity index 100% rename from infrastructure/projectsend/env/projectsend.env rename to infrastructure/services/projectsend/env/projectsend.env diff --git a/infrastructure/projectsend/env/projectsend_db.env b/infrastructure/services/projectsend/env/projectsend_db.env similarity index 100% rename from infrastructure/projectsend/env/projectsend_db.env rename to infrastructure/services/projectsend/env/projectsend_db.env diff --git a/infrastructure/psitransfer/docker-compose.psitransfer.yml b/infrastructure/services/psitransfer/docker-compose.psitransfer.yml similarity index 93% rename from infrastructure/psitransfer/docker-compose.psitransfer.yml rename to infrastructure/services/psitransfer/docker-compose.psitransfer.yml index 21b27d7..e6bcd5e 100644 --- a/infrastructure/psitransfer/docker-compose.psitransfer.yml +++ b/infrastructure/services/psitransfer/docker-compose.psitransfer.yml @@ -10,7 +10,7 @@ services: depends_on: - caddy env_file: - - ./psitransfer/env/psitransfer.env + - ./env/psitransfer.env volumes: - psitransfer_data:/data networks: diff --git a/infrastructure/psitransfer/env/psitransfer.env b/infrastructure/services/psitransfer/env/psitransfer.env similarity index 100% rename from infrastructure/psitransfer/env/psitransfer.env rename to infrastructure/services/psitransfer/env/psitransfer.env diff --git a/infrastructure/qbittorrent/docker-compose.qbittorrent.yml b/infrastructure/services/qbittorrent/docker-compose.qbittorrent.yml similarity index 93% rename from infrastructure/qbittorrent/docker-compose.qbittorrent.yml rename to infrastructure/services/qbittorrent/docker-compose.qbittorrent.yml index 04d0f01..166501f 100644 --- a/infrastructure/qbittorrent/docker-compose.qbittorrent.yml +++ b/infrastructure/services/qbittorrent/docker-compose.qbittorrent.yml @@ -9,7 +9,7 @@ services: depends_on: - caddy env_file: - - ./qbittorrent/env/qbittorrent.env + - ./env/qbittorrent.env environment: - PUID=${PUID:-1000} - PGID=${PGID:-1000} diff --git a/infrastructure/qbittorrent/env/qbittorrent.env b/infrastructure/services/qbittorrent/env/qbittorrent.env similarity index 100% rename from infrastructure/qbittorrent/env/qbittorrent.env rename to infrastructure/services/qbittorrent/env/qbittorrent.env diff --git a/infrastructure/stirlingpdf/docker-compose.stirlingpdf.yml b/infrastructure/services/stirlingpdf/docker-compose.stirlingpdf.yml similarity index 92% rename from infrastructure/stirlingpdf/docker-compose.stirlingpdf.yml rename to infrastructure/services/stirlingpdf/docker-compose.stirlingpdf.yml index 676c4c4..348dc25 100644 --- a/infrastructure/stirlingpdf/docker-compose.stirlingpdf.yml +++ b/infrastructure/services/stirlingpdf/docker-compose.stirlingpdf.yml @@ -9,7 +9,7 @@ services: depends_on: - caddy env_file: - - ./stirlingpdf/env/stirlingpdf.env + - ./env/stirlingpdf.env volumes: - stirlingpdf_config:/configs - stirlingpdf_tessdata:/usr/share/tessdata diff --git a/infrastructure/stirlingpdf/env/stirlingpdf.env b/infrastructure/services/stirlingpdf/env/stirlingpdf.env similarity index 100% rename from infrastructure/stirlingpdf/env/stirlingpdf.env rename to infrastructure/services/stirlingpdf/env/stirlingpdf.env diff --git a/infrastructure/syncthing/docker-compose.syncthing.yml b/infrastructure/services/syncthing/docker-compose.syncthing.yml similarity index 94% rename from infrastructure/syncthing/docker-compose.syncthing.yml rename to infrastructure/services/syncthing/docker-compose.syncthing.yml index c495303..1ffac7c 100644 --- a/infrastructure/syncthing/docker-compose.syncthing.yml +++ b/infrastructure/services/syncthing/docker-compose.syncthing.yml @@ -9,7 +9,7 @@ services: - caddy restart: on-failure:5 env_file: - - ./syncthing/env/syncthing.env + - ./env/syncthing.env environment: - PUID=${PUID:-1000} - PGID=${PGID:-1000} diff --git a/infrastructure/syncthing/env/syncthing.env b/infrastructure/services/syncthing/env/syncthing.env similarity index 100% rename from infrastructure/syncthing/env/syncthing.env rename to infrastructure/services/syncthing/env/syncthing.env diff --git a/infrastructure/transmission/docker-compose.transmission.yml b/infrastructure/services/transmission/docker-compose.transmission.yml similarity index 94% rename from infrastructure/transmission/docker-compose.transmission.yml rename to infrastructure/services/transmission/docker-compose.transmission.yml index bd4cd03..510d76f 100644 --- a/infrastructure/transmission/docker-compose.transmission.yml +++ b/infrastructure/services/transmission/docker-compose.transmission.yml @@ -9,7 +9,7 @@ services: depends_on: - caddy env_file: - - ./transmission/env/transmission.env + - ./env/transmission.env environment: - PUID=${PUID:-1000} - PGID=${PGID:-1000} diff --git a/infrastructure/transmission/env/transmission.env b/infrastructure/services/transmission/env/transmission.env similarity index 100% rename from infrastructure/transmission/env/transmission.env rename to infrastructure/services/transmission/env/transmission.env diff --git a/infrastructure/uptime-kuma/docker-compose.uptime-kuma.yml b/infrastructure/services/uptime-kuma/docker-compose.uptime-kuma.yml similarity index 100% rename from infrastructure/uptime-kuma/docker-compose.uptime-kuma.yml rename to infrastructure/services/uptime-kuma/docker-compose.uptime-kuma.yml diff --git a/infrastructure/wordpress/config/wordpress/php.ini b/infrastructure/services/wordpress/config/wordpress/php.ini similarity index 100% rename from infrastructure/wordpress/config/wordpress/php.ini rename to infrastructure/services/wordpress/config/wordpress/php.ini diff --git a/infrastructure/wordpress/docker-compose.adminer.yml b/infrastructure/services/wordpress/docker-compose.adminer.yml similarity index 89% rename from infrastructure/wordpress/docker-compose.adminer.yml rename to infrastructure/services/wordpress/docker-compose.adminer.yml index 8018dde..f273a93 100644 --- a/infrastructure/wordpress/docker-compose.adminer.yml +++ b/infrastructure/services/wordpress/docker-compose.adminer.yml @@ -7,7 +7,7 @@ services: - adminer restart: on-failure:5 env_file: - - ./wordpress/env/adminer.env + - ./env/adminer.env depends_on: - wordpress_db - caddy diff --git a/infrastructure/wordpress/docker-compose.wordpress.yml b/infrastructure/services/wordpress/docker-compose.wordpress.yml similarity index 86% rename from infrastructure/wordpress/docker-compose.wordpress.yml rename to infrastructure/services/wordpress/docker-compose.wordpress.yml index 4065fb0..5bd535e 100644 --- a/infrastructure/wordpress/docker-compose.wordpress.yml +++ b/infrastructure/services/wordpress/docker-compose.wordpress.yml @@ -10,9 +10,9 @@ services: - wordpress_db - caddy env_file: - - ./wordpress/env/wordpress.env + - ./env/wordpress.env volumes: - - ./wordpress/config/wordpress/php.ini:/usr/local/etc/php/conf.d/custom.ini:ro + - ./config/wordpress/php.ini:/usr/local/etc/php/conf.d/custom.ini:ro - wordpress:/var/www/html:rw networks: - infra-network @@ -32,7 +32,7 @@ services: volumes: - wordpress_db:/var/lib/mysql:rw env_file: - - ./wordpress/env/wordpress_db.env + - ./env/wordpress_db.env command: '--default-authentication-plugin=mysql_native_password' networks: - infra-network @@ -48,7 +48,7 @@ services: - wordpress restart: on-failure:5 env_file: - - ./wordpress/env/wordpress_backup.env + - ./env/wordpress_backup.env volumes: - wordpress_backup:/mnt/restic - wordpress_db:/data/wordpress_db:ro diff --git a/infrastructure/wordpress/env/adminer.env b/infrastructure/services/wordpress/env/adminer.env similarity index 100% rename from infrastructure/wordpress/env/adminer.env rename to infrastructure/services/wordpress/env/adminer.env diff --git a/infrastructure/wordpress/env/wordpress.env b/infrastructure/services/wordpress/env/wordpress.env similarity index 100% rename from infrastructure/wordpress/env/wordpress.env rename to infrastructure/services/wordpress/env/wordpress.env diff --git a/infrastructure/wordpress/env/wordpress_backup.env b/infrastructure/services/wordpress/env/wordpress_backup.env similarity index 100% rename from infrastructure/wordpress/env/wordpress_backup.env rename to infrastructure/services/wordpress/env/wordpress_backup.env diff --git a/infrastructure/wordpress/env/wordpress_db.env b/infrastructure/services/wordpress/env/wordpress_db.env similarity index 100% rename from infrastructure/wordpress/env/wordpress_db.env rename to infrastructure/services/wordpress/env/wordpress_db.env diff --git a/infrastructure/yacht/docker-compose.yacht.yml b/infrastructure/services/yacht/docker-compose.yacht.yml similarity index 93% rename from infrastructure/yacht/docker-compose.yacht.yml rename to infrastructure/services/yacht/docker-compose.yacht.yml index 2fa1a73..1a1454d 100644 --- a/infrastructure/yacht/docker-compose.yacht.yml +++ b/infrastructure/services/yacht/docker-compose.yacht.yml @@ -9,7 +9,7 @@ services: depends_on: - caddy env_file: - - ./yacht/env/yacht.env + - ./env/yacht.env volumes: - /var/run/docker.sock:/var/run/docker.sock - yacht_config:/config diff --git a/infrastructure/yacht/env/yacht.env b/infrastructure/services/yacht/env/yacht.env similarity index 100% rename from infrastructure/yacht/env/yacht.env rename to infrastructure/services/yacht/env/yacht.env