Ops: set up automatic PostgreSQL backups

Aperta
#299 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
18/100
Tipo di issue
Funzionalità
Chiarezza
Abbastanza chiara
Stato di attività
Tranquilla
Stack tecnologico
docker, docker-compose, postgresql

Direzione di ricerca

Start by reading the POSTGRES_* settings and the external pg_net network in deployment/portainer/docker-compose.portainer.yaml, then the postgres service in docker-compose.yaml. The approach (pg_dump, pgBackRest, snapshots) is still open, so agree it with the maintainer before writing anything. Done means a scheduled, off-site, encrypted backup with a documented and tested restore, plus an alert on failure.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

enhancement

Goal

Establish automated, restorable backups for the production Meshflow PostgreSQL database (Django/Celery/Channels data).

Context

  • Production stack: Portainer compose — deployment/portainer/docker-compose.portainer.yaml (API/workers use POSTGRES_* env; DB likely on external pg_net network).
  • Local/dev: postgres service in root docker-compose.yaml (postgres:17-alpine for dev — production version may differ).
  • No automated backup process is documented or wired in-repo today.

Scope

  • Choose approach: scheduled pg_dump (custom format + compression), pgBackRest, cloud provider snapshots, or host/volume backup — document rationale
  • Schedule (e.g. nightly full + optional WAL/archiving if RPO/RTO require it)
  • Off-site / off-volume destination (S3-compatible, second host, etc.) — backups on same disk as data are not sufficient
  • Retention policy (e.g. 7 daily, 4 weekly)
  • Encryption at rest for backup files (if stored outside trust boundary)
  • Runbook: restore procedure + tested restore drill on staging (or disposable clone)
  • Monitoring/alerting on backup job failure
  • Document in docs/ or deployment/ (env vars, cron/compose sidecar, credentials handling — no secrets in git)

Out of scope

  • Neo4j backup (separate ticket if needed)
  • Redis persistence strategy (separate concern)

Acceptance

  • Automated backups run on schedule without manual intervention
  • Operator can restore DB to a point in time within agreed RPO using documented steps
  • Failed backup run generates an alert or visible log/metric
Lingua principale
Python
Stelle
1
Fork
0
Merge medio
1g 20h
PR unite (30g)
5

Preparare l'ambiente

  • Include un Dockerfile o un file Docker Compose
  • Ha un modello di pull request
  • Nessuna guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di pskillen/meshflow-api

Tutte le issue di pskillen/meshflow-api

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.