Backups and updates
Working with backups
Creating a backup
- Start
Pepeunitso that thebackupscript has access to the databases and thebackendversion:bashdocker compose up -d - Run backup creation without stopping the containers:bash
sudo ./backup.sh backup
Restoring from a backup
- Stop the instance:bash
docker compose down - Restore the version from a
backup:bashsudo ./backup.sh restore backups/backup_name.tar - Start
Pepeunit:bashdocker compose up -d
Updating
- Create a
backup:bashsudo ./backup.sh backup - Update the repository:bash
git pull - Update
envvariables. Existing secret32‑byte keyswill NOT be changed. Other variables will be generated just like during the first generation. If you manually edited files inenv/.env.<service-name>, your changes will be REMOVED, so be sure to make abackupbefore running this command. If you have very fine‑tuned settings, change them manually by editing the files inenv/.env.<service-name>.bashpython make_env.py - Start
Pepeunit:bashdocker compose up -d - After the backend starts correctly, run integration tests as an Administrator. If errors appear, check the related container logs or open an
issue
Updating 1.2.1 -> 1.3.0
INFO
This update is more involved because PostgreSQL changed its directory layout when going from 17.6 to 18.6
DANGER
ClickHouse 26.8.2 requires the x86-64-v3 CPU instruction set or newer. If you want to run the instance on CPUs without those instructions, use version 25.8.32 in docker-compose.yml: clickhouse:25.8.32.
In a regular update, backup is a safety net. Here backup is used directly: old data from 1.2.1 is restored on top of the 1.3.0 compose.
- Create a
backupbashsudo ./backup.sh backup - Stop the instance completelybash
docker compose down - Remove the old
volumesbashdocker volume rm pepeunit_deploy_postgres_data pepeunit_deploy_clickhouse_data pepeunit_deploy_emqx_log pepeunit_deploy_emqx_data - Update the repositorybash
git pull - Pull the new imagesbash
docker compose pull - Restore the
1.2.1data on top of the1.3.0compose. Substitute yourbackupfile name:bashsudo ./backup.sh restore backups/2026-09-12_04-05-00_v1.2.1_pepeunit_backup.tar - After the backend starts correctly, run integration tests as an Administrator. If errors appear, check the related container logs or open an
issue