2 Commits

Author SHA1 Message Date
bdc6e77e40 fix backup and restore 2023-11-11 13:18:40 +01:00
3wc
b26d957cad Add scary release note warning 2023-11-09 20:35:00 +00:00
2 changed files with 12 additions and 3 deletions

View File

@ -51,7 +51,8 @@ services:
backupbot.backup.pre-hook: sh -c 'pg_dump -U "$$POSTGRES_USER" -Fc "$$POSTGRES_DB" | gzip > "/postgres.dump.gz"'
backupbot.backup.path: "/postgres.dump.gz"
backupbot.backup.post-hook: "rm -f /postgres.dump.gz"
backupbot.restore.post-hook: sh -c 'gzip -d /postgres.dump.gz && pg_restore -U "$$POSTGRES_USER" --dbname="$$PLAUSIBLE_DB" < /postgres.dump && rm /postgres.dump'
backupbot.restore: "true"
backupbot.restore.post-hook: sh -c 'gzip -d /postgres.dump.gz && pg_restore --clean -U "$$POSTGRES_USER" --dbname="$$PLAUSIBLE_DB" < /postgres.dump && rm -f /postgres.dump'
plausible_events_db:
image: clickhouse/clickhouse-server:23.4.2.11-alpine
@ -74,8 +75,8 @@ services:
backupbot.backup.pre-hook: clickhouse-backup create events
backupbot.backup.path: "/var/lib/clickhouse/backup/events"
backupbot.backup.post-hook: "rm -rf /var/lib/clickhouse/backup/events"
backupbot.restore.post-hook: clickhouse-backup restore events
backupbot.resoter.post-hook: "rm -rf /var/lib/clickhouse/backup/events"
backupbot.restore: "true"
backupbot.restore.post-hook: clickhouse-backup restore --rm events && rm -rf /var/lib/clickhouse/backup/events"
volumes:
db-data:

8
release/3.0.0+v2.0.0 Normal file
View File

@ -0,0 +1,8 @@
⚠ WARNING! ⚠
This major version upgrade of Plausible requires running a manual data migration
-- otherwise you'll see all historical data disappear (don't worry, it's
"probably" still there).
Take a manual docker volume backup, then see here, and strap in:
https://github.com/plausible/analytics/discussions/3132