From 058f5b7ca70259c85a7f58ace7b8cfd6f4379183 Mon Sep 17 00:00:00 2001 From: Stefan H Date: Wed, 27 Mar 2024 21:08:10 +0100 Subject: [PATCH 1/4] Authentik-Container-Name korrigiert --- roles/unhb_backup_scripts/templates/restic-backup_unhb4.sh.j2 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/roles/unhb_backup_scripts/templates/restic-backup_unhb4.sh.j2 b/roles/unhb_backup_scripts/templates/restic-backup_unhb4.sh.j2 index 64f69f9..404043c 100755 --- a/roles/unhb_backup_scripts/templates/restic-backup_unhb4.sh.j2 +++ b/roles/unhb_backup_scripts/templates/restic-backup_unhb4.sh.j2 @@ -18,7 +18,7 @@ fi echo "Now dumping databases, this might take a while..." set -x docker exec -t matrix_sql.server4 pg_dumpall -c -U user_synapse_unhb > /opt/db_dumps/db-dump-synapse_db.sql -docker exec -t authentik-postgresql-1 pg_dumpall -c -U authentik > /opt/db_dumps/db-dump-authentik_db.sql +docker exec -t authentik-postgresql-1.server4 pg_dumpall -c -U authentik > /opt/db_dumps/db-dump-authentik_db.sql docker exec -t hedgedoc_sql15.server4 pg_dumpall -c -U md > /opt/db_dumps/db-dump-hedgedoc_db.sql docker exec -t tandoor-tandoor_recipes_db-1 pg_dumpall -c -U djangouser > /opt/db_dumps/db-dump-tandoor_db.sql docker exec -t wikijs-wikijs-db-1 pg_dumpall -c -U wikijs > /opt/db_dumps/db-dump-wikijs_db.sql From ccb4197aa019fe8d15526faf8e44353c3043d3cd Mon Sep 17 00:00:00 2001 From: Stefan H Date: Wed, 27 Mar 2024 21:36:57 +0100 Subject: [PATCH 2/4] =?UTF-8?q?kleiner=20fix=20weil=20sonst=20Certs=20nich?= =?UTF-8?q?t=20erneuert=20werden=20k=C3=B6nnen?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- roles/traefik_docker/templates/traefik.yml.j2 | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/roles/traefik_docker/templates/traefik.yml.j2 b/roles/traefik_docker/templates/traefik.yml.j2 index 800e6b8..b664d0c 100644 --- a/roles/traefik_docker/templates/traefik.yml.j2 +++ b/roles/traefik_docker/templates/traefik.yml.j2 @@ -1,5 +1,4 @@ - entryPoints: web: address: ":80" @@ -29,7 +28,7 @@ certificatesResolvers: email: "{{ letsencrypt_email }}" storage: "/letsencrypt/acme.json" #caServer: "https://acme-staging-v02.api.letsencrypt.org/directory" - tlsChallenge: + tlsChallenge: true providers: From a6b1b4c14856fd52db54b406892fe8eb24ae3f55 Mon Sep 17 00:00:00 2001 From: Stefan Heinrichsen Date: Fri, 29 Mar 2024 15:27:49 +0100 Subject: [PATCH 3/4] =?UTF-8?q?SQL=20Dumps=20werden=20nun=20gepackt;=20au?= =?UTF-8?q?=C3=9Ferdem=20einige=20Verzeichnisse=20aus=20dem=20Backup=20ent?= =?UTF-8?q?fernt=20da=20sie=20nicht=20gesichert=20werden=20m=C3=BCssen?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../templates/restic-backup_unhb4.sh.j2 | 27 +++++++++---------- 1 file changed, 13 insertions(+), 14 deletions(-) diff --git a/roles/unhb_backup_scripts/templates/restic-backup_unhb4.sh.j2 b/roles/unhb_backup_scripts/templates/restic-backup_unhb4.sh.j2 index 404043c..0d07b84 100755 --- a/roles/unhb_backup_scripts/templates/restic-backup_unhb4.sh.j2 +++ b/roles/unhb_backup_scripts/templates/restic-backup_unhb4.sh.j2 @@ -17,17 +17,17 @@ fi echo "Now dumping databases, this might take a while..." set -x -docker exec -t matrix_sql.server4 pg_dumpall -c -U user_synapse_unhb > /opt/db_dumps/db-dump-synapse_db.sql -docker exec -t authentik-postgresql-1.server4 pg_dumpall -c -U authentik > /opt/db_dumps/db-dump-authentik_db.sql -docker exec -t hedgedoc_sql15.server4 pg_dumpall -c -U md > /opt/db_dumps/db-dump-hedgedoc_db.sql -docker exec -t tandoor-tandoor_recipes_db-1 pg_dumpall -c -U djangouser > /opt/db_dumps/db-dump-tandoor_db.sql -docker exec -t wikijs-wikijs-db-1 pg_dumpall -c -U wikijs > /opt/db_dumps/db-dump-wikijs_db.sql -docker exec -t nextcloud_sql.server4 sh -c "exec mariadb-dump --all-databases -uroot --password=$MARIADB_PASSWORD_NEXTCLOUD" > /opt/db_dumps/db-dump-nextcloud_db.sql -docker exec -t etherpad_sql.server4 sh -c "exec mariadb-dump --all-databases -uroot --password=$MARIADB_PASSWORD_ETHERPAD" > /opt/db_dumps/db-dump-etherpad_db.sql -docker exec -t jverein_sql.server4 sh -c "exec mariadb-dump --all-databases -uroot --password=$MARIADB_PASSWORD_JVEREIN" > /opt/db_dumps/db-dump-jverein_db.sql -docker exec -t url-shortener_sql.server4 sh -c "exec mariadb-dump --all-databases -uroot --password=$MARIADB_PASSWORD_URLSHORTENER" > /opt/db_dumps/db-dump-urlshortener_db.sql -docker exec -t wiki_sql.server4 sh -c "exec mariadb-dump --all-databases -uroot --password=$MARIADB_PASSWORD_WIKI" > /opt/db_dumps/db-dump-wiki_db.sql -docker exec -t wordpress_sql.server4 sh -c "exec mysqldump --all-databases -uroot --password=$MARIADB_PASSWORD_WORDPRESS" > /opt/db_dumps/db-dump-wordpress_db.sql +docker exec -t matrix_sql.server4 pg_dumpall -c -U user_synapse_unhb | bzip2 > /opt/db_dumps/db-dump-synapse_db.sql.bz2 +docker exec -t authentik-postgresql-1.server4 pg_dumpall -c -U authentik | bzip2 > /opt/db_dumps/db-dump-authentik_db.sql.bz2 +docker exec -t hedgedoc_sql15.server4 pg_dumpall -c -U md | bzip2 > /opt/db_dumps/db-dump-hedgedoc_db.sql.bz2 +docker exec -t tandoor-tandoor_recipes_db-1 pg_dumpall -c -U djangouser | bzip2 > /opt/db_dumps/db-dump-tandoor_db.sql.bz2 +docker exec -t wikijs-wikijs-db-1 pg_dumpall -c -U wikijs | bzip2 > /opt/db_dumps/db-dump-wikijs_db.sql.bz2 +docker exec -t nextcloud_sql.server4 sh -c "exec mariadb-dump --all-databases -uroot --password=$MARIADB_PASSWORD_NEXTCLOUD" | bzip2 > /opt/db_dumps/db-dump-nextcloud_db.sql.bz2 +docker exec -t etherpad_sql.server4 sh -c "exec mariadb-dump --all-databases -uroot --password=$MARIADB_PASSWORD_ETHERPAD" | bzip2 > /opt/db_dumps/db-dump-etherpad_db.sql.bz2 +docker exec -t jverein_sql.server4 sh -c "exec mariadb-dump --all-databases -uroot --password=$MARIADB_PASSWORD_JVEREIN" | bzip2 > /opt/db_dumps/db-dump-jverein_db.sql.bz2 +docker exec -t url-shortener_sql.server4 sh -c "exec mariadb-dump --all-databases -uroot --password=$MARIADB_PASSWORD_URLSHORTENER" | bzip2 > /opt/db_dumps/db-dump-urlshortener_db.sql.bz2 +docker exec -t wiki_sql.server4 sh -c "exec mariadb-dump --all-databases -uroot --password=$MARIADB_PASSWORD_WIKI" | bzip2 > /opt/db_dumps/db-dump-wiki_db.sql.bz2 +docker exec -t wordpress_sql.server4 sh -c "exec mysqldump --all-databases -uroot --password=$MARIADB_PASSWORD_WORDPRESS" | bzip2 > /opt/db_dumps/db-dump-wordpress_db.sql.bz2 set +x restic backup --verbose \ @@ -35,8 +35,7 @@ restic backup --verbose \ /home \ /opt \ /root \ - /srv \ - /var/lib/docker/volumes/ \ - /var/www + /srv +# /var/lib/docker/volumes/ \ echo "done! :)" From eb0d41debf75e70934f6f98ffb30ec58aeec3a9b Mon Sep 17 00:00:00 2001 From: Stefan Heinrichsen Date: Fri, 29 Mar 2024 15:29:28 +0100 Subject: [PATCH 4/4] Backupzeit auf 1 Uhr Nachts vorverlegt --- group_vars/all/all.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/group_vars/all/all.yml b/group_vars/all/all.yml index eef76ef..f522bdf 100644 --- a/group_vars/all/all.yml +++ b/group_vars/all/all.yml @@ -6,4 +6,4 @@ APT_Periodic_AutocleanInterval: "7" APT_Periodic_Unattended_Upgrade: "1" restic_repository_location: "sftp:restic_{{ inventory_hostname }}@proxmox.unhb.space:/storage/restic-backup/" -restic_start_time: "*-*-* 3:00:00" +restic_start_time: "*-*-* 1:00:00"