# Existing deployment migration The live PostgreSQL and Valkey instances are already Helm releases. The goal is to adopt their resources into one `gramps` Helm release without replacing the PostgreSQL PVC. 1. Run `./backup.sh` and verify the gzip file. 2. Run `./bootstrap-secrets.sh`. This separates live credentials into runtime, PostgreSQL, and Valkey Secrets without printing them. 3. Run `./preflight.sh`. It verifies the required Secret keys, bound PVCs, StatefulSet immutable fields, and a server-side Helm dry run. 4. Install the published OCI package with `./deploy.sh`. The script uses `--take-ownership`; the rendered StatefulSets deliberately retain the old names, selectors, services, and volume-claim-template names. 5. Verify PostgreSQL, Gramps Web, Celery, OIDC, media, and the public URL. 6. Back up the old Helm release Secrets, then delete only the release metadata Secrets named `sh.helm.release.v1.postgresql.*` and `sh.helm.release.v1.valkey.*`. Do not uninstall the old releases. PostgreSQL 18 to a newer 18.x image is a minor upgrade. PostgreSQL 18 to 19 is a major upgrade and requires a separately planned `pg_upgrade` or dump/restore.