Ajout de backup.sh
Ajout de backup.sh pour sauvegarder au format tar.gz dans le dossier backups
la base de donnée et la configuration keycloak
Je ne sauvegarde pas les thèmes custom qui théoriquement sont gité.
Merge request reports
Activity
assigned to @elian
requested review from @dbeniamine
@dbeniamine Si ta 5 minutes je suis pas contre un review comme c'est la première fois que je fais ça.
Je me suis inspiré du backup.sh de nextcloud
added WF::0_need info label
modification faite.
@dbeniamine J'en ai profité pour conditionnellement utiliser
docker-compose
oudocker compose
en fonction de ce qui est installé
added 1 commit
- 147e952f - Dump database with docker-compose or docker compose
- Resolved by Elian Loraux
- Resolved by David Beniamine
- backup.sh 0 → 100644
1 #!/bin/bash 2 3 echo "Backing up Keycloak DB and config" 4 5 if [ ! -d "backups" ]; then 6 echo "backups does exist. Create this." changed this line in version 3 of the diff
requested review from @dbeniamine
@dbeniamine modification faites, dit moi si tout est bon
- Resolved by David Beniamine
- backup.sh 0 → 100644
1 #!/bin/bash 2 3 echo "Backing up Keycloak DB and config" 4 5 if [ -z "$MARIADB_PASS" ]; then 6 echo "Error: the MARIADB_PASS variable is not set or is empty." 7 exit 1 8 fi 9 10 if [ ! -d "backups" ]; then 11 mkdir "backups" 12 fi changed this line in version 5 of the diff
- backup.sh 0 → 100644
1 #!/bin/bash 2 3 echo "Backing up Keycloak DB and config" 4 5 if [ -z "$MARIADB_PASS" ]; then 6 echo "Error: the MARIADB_PASS variable is not set or is empty." 7 exit 1 8 fi 9 10 if [ ! -d "backups" ]; then 11 mkdir "backups" 12 fi 13 14 out="backups/keycloak_$(date +%Y%m%d_%H%M).tar.gz" changed this line in version 5 of the diff