borgmatic

This commit is contained in:
root 2026-02-16 20:36:03 +00:00 committed by kleines Filmröllchen
parent 7ed00c4efc
commit c36aac5dbb
Signed by: filmroellchen
SSH key fingerprint: SHA256:UMhcHaeI+VGsiUL2Drpw3aj1iRiQUlx8nxZqUPvoaVw
3 changed files with 81 additions and 2 deletions

1
.gitignore vendored
View file

@ -1,2 +1,3 @@
.env*
.id*

78
borgmatic-config.yaml Normal file
View file

@ -0,0 +1,78 @@
source_directories:
- /etc
- /var/lib/pretix
- /var/lib/pretalx
repositories:
- path: ssh://hosting202341@ae89d.netcup.net/backup/vm-chaosevent-01
label: netcup
- path: ssh://ctbk-backup.ext.selfnet.de/media/backupstorage/vm-chaosevent-01
label: selfnet
working_directory: /etc/events
# exclude_patterns:
# - '*.pyc'
# - /home/*/.cache
# - '*/.vim*.tmp'
# - /etc/ssl
# - /home/user/path with spaces
# exclude_from:
# - /etc/borgmatic/excludes
exclude_caches: true
exclude_nodump: true
encryption_passcommand: cat /etc/borgmatic/key
compression: zstd,10
upload_rate_limit: 10000
retries: 3
retry_wait: 10
ssh_command: ssh -i /etc/events/.id_ed25519
borg_base_directory: /var/lib/borg
borg_cache_directory: /var/cache/borg
archive_name_format: 'events-{now:%Y-%m-%dT%H:%M:%S}'
keep_within: 1d
keep_daily: 7
keep_weekly: 4
keep_monthly: 12
# keep_yearly: 1
checks:
- name: repository
frequency: 1 week
- name: extract
frequency: 3 weeks
only_run_on:
- Monday
check_last: 3
postgresql_databases:
- name: all
username: postgres
format: plain
compression: none
uptime_kuma:
push_url: https://status.ctbk.de/api/push/bjjOh4jeSZO5pNg2L3WkudJxR2RK2ccs
# loki:
# Grafana loki log URL to notify when a backup begins,
# ends, or fails.
# url: http://localhost:3100/loki/api/v1/push
# Allows setting custom labels for the logging stream. At
# least one label is required. "__hostname" gets replaced by
# the machine hostname automatically. "__config" gets replaced
# by the name of the configuration file. "__config_path" gets
# replaced by the full path of the configuration file.
# labels:
# app: borgmatic
# config: __config
# hostname: __hostname

View file

@ -1,5 +1,5 @@
# TYPE DATABASE USER ADDRESS METHOD
# Database administrative login by Unix domain socket, do not disable
local all postgres peer
local all pretix trust
local all pretalx trust
local all all trust