From 0097fe09db3c7413e12b11a0cc97935cd288a4dc Mon Sep 17 00:00:00 2001 From: Kevin Veen-Birkenbach Date: Wed, 31 Aug 2022 20:22:56 +0200 Subject: [PATCH] changed root password --- roles/docker-akaunting/readme.md | 45 +++++++++++++++++++++- roles/docker-akaunting/templates/db.env.j2 | 2 +- 2 files changed, 45 insertions(+), 2 deletions(-) diff --git a/roles/docker-akaunting/readme.md b/roles/docker-akaunting/readme.md index 3cc9bf79..19469451 100644 --- a/roles/docker-akaunting/readme.md +++ b/roles/docker-akaunting/readme.md @@ -1,11 +1,14 @@ # docker akaunting + ## clean up + ### delete all containers ```bash export COMPOSE_HTTP_TIMEOUT=600 export DOCKER_CLIENT_TIMEOUT=600 cd /home/administrator/docker-compose/akaunting/ && docker-compose down ``` + ### delete all volumes ```bash docker volume rm akaunting_akaunting-data akaunting_akaunting-db akaunting_akaunting-modules @@ -17,11 +20,48 @@ cd /home/administrator/docker-compose/akaunting/ export COMPOSE_HTTP_TIMEOUT=600 export DOCKER_CLIENT_TIMEOUT=600 AKAUNTING_SETUP=true docker-compose -p akaunting up -d +``` + +Check Webinterface and then execute: + +```bash docker-compose down docker-compose -p akaunting up -d ``` +## enter akaunting container -## rebuild +docker exec -it akaunting bash + +curl https://getcomposer.org/download/2.4.1/composer.phar --output composer.phar + +## manuel update +```bash +php /var/www/html/artisan update:all +php /var/www/html/artisan update:db +``` + +## composer +curl http://some.url --output + +php composer.phar install + + +## recover + +### recover all volumes +Keep in mind to set the $akaunting_db_password! + +```bash +cd /usr/local/bin/docker-volume-backup && +machine_id="$(sha256sum /etc/machine-id)" && +bash docker-volume-recover.sh akaunting_akaunting-modules ${machine_id:0:64} && +bash docker-volume-recover.sh akaunting_akaunting-data ${machine_id:0:64} && +bash docker-volume-recover.sh akaunting_akaunting-db ${machine_id:0:64} akaunting-db "$akaunting_db_password" akaunting +``` + +docker exec -it akaunting-db /bin/mysql -u admin --password=$akaunting_db_password akaunting + +### rebuild containers ```bash cd /home/administrator/docker-compose/akaunting/ export COMPOSE_HTTP_TIMEOUT=600 @@ -34,3 +74,6 @@ docker-compose -p akaunting up -d --force-recreate ## Further information - https://github.com/akaunting/docker +- https://akaunting.com/forum/discussion/installation-update/updating-to-300-failed-cant-manually-update-either +- https://akaunting.com/forum/discussion/installation-update/not-able-to-update-core +- https://akaunting.com/forum/discussion/installation-update/update-to-203-not-able-to-finalize-core-installation \ No newline at end of file diff --git a/roles/docker-akaunting/templates/db.env.j2 b/roles/docker-akaunting/templates/db.env.j2 index 6212d9e9..7ef2704d 100644 --- a/roles/docker-akaunting/templates/db.env.j2 +++ b/roles/docker-akaunting/templates/db.env.j2 @@ -6,4 +6,4 @@ MYSQL_USER=admin MYSQL_PASSWORD={{akaunting_database_password}} # You should probably leave this -MYSQL_RANDOM_ROOT_PASSWORD=yes +MYSQL_ROOT_PASSWORD={{akaunting_database_password}}