{"id":48581412,"url":"https://github.com/controlplane-com/backup-images","last_synced_at":"2026-04-08T17:02:33.764Z","repository":{"id":345823652,"uuid":"1187520296","full_name":"controlplane-com/backup-images","owner":"controlplane-com","description":"A repository containing source code for backup images used in the Control Plane templates catalog.","archived":false,"fork":false,"pushed_at":"2026-03-20T21:04:41.000Z","size":10,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-21T12:17:34.900Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/controlplane-com.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2026-03-20T20:27:47.000Z","updated_at":"2026-03-20T21:04:44.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/controlplane-com/backup-images","commit_stats":null,"previous_names":["controlplane-com/backup-images"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/controlplane-com/backup-images","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/controlplane-com%2Fbackup-images","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/controlplane-com%2Fbackup-images/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/controlplane-com%2Fbackup-images/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/controlplane-com%2Fbackup-images/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/controlplane-com","download_url":"https://codeload.github.com/controlplane-com/backup-images/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/controlplane-com%2Fbackup-images/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31564915,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-08T14:31:17.711Z","status":"ssl_error","status_checked_at":"2026-04-08T14:31:17.202Z","response_time":54,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-04-08T17:02:32.060Z","updated_at":"2026-04-08T17:02:33.750Z","avatar_url":"https://github.com/controlplane-com.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Control Plane Backup Images\n\nThis repository contains the source code for the database backup Docker images used in the [Control Plane Templates Catalog](https://docs.controlplane.com/template-catalog).\n\nBuilt images are published to DockerHub at [hub.docker.com/u/controlplanecorporation](https://hub.docker.com/u/controlplanecorporation).\n\n---\n\n## Images\n\n| Image | Base | Tool |\n|---|---|---|\n| `mysql-backup` | `mysql:8-debian` | `mysqldump` |\n| `mongo-backup` | `mongo:7-jammy` | `mongodump` |\n| `postgres-backup` | `postgres:18` | `pg_dumpall` |\n| `redis-backup` | `redis:7-bookworm` | `redis-cli --rdb` |\n| `tidb-backup` | `debian:bookworm-slim` | TiDB BR |\n\n\u003e **Manticore Search:** The backup source code for Manticore Search is maintained in a separate repository at [github.com/controlplane-com/manticore-orchestrator](https://github.com/controlplane-com/manticore-orchestrator).\n\nEach image runs a single backup on container start and exits. They are intended to be run as cron jobs or one-shot workloads within Control Plane.\n\n### Image Versioning\n\n- **MySQL, MongoDB, Redis** — versioned independently of the database version, starting at `1.0` and incremented sequentially (e.g., `1.0`, `1.1`, `1.2`).\n- **PostgreSQL** — image versions are tied to the major PostgreSQL version. The minor version increments independently. For example, `17.1.0` targets `postgres:17` and `18.1.0` targets `postgres:18`.\n- **TiDB** — image versions match the TiDB release. For example, `8.5.3` corresponds to `pingcap/tidb:8.5.3`.\n\n---\n\n## Cloud Storage Providers\n\nAll images support backing up to either AWS S3 or Google Cloud Storage. The target is controlled by the `BACKUP_PROVIDER` environment variable.\n\nCloud credentials must be available at runtime — either via workload identity (recommended) or by injecting the appropriate environment variables (`AWS_ACCESS_KEY_ID` / `AWS_SECRET_ACCESS_KEY` for AWS, or `GOOGLE_APPLICATION_CREDENTIALS` for GCP).\n\n---\n\n## Environment Variables\n\n### Common (all images)\n\n| Variable | Description |\n|---|---|\n| `BACKUP_PROVIDER` | `aws` or `gcp` |\n| `BACKUP_BUCKET` | Bucket name |\n| `BACKUP_PREFIX` | Path prefix within the bucket |\n\n### MySQL\n\n| Variable | Description |\n|---|---|\n| `MYSQL_HOST` | Database host |\n| `MYSQL_PORT` | Database port |\n| `MYSQL_ROOT_PASSWORD` | Root password |\n\n### MongoDB\n\n| Variable | Description |\n|---|---|\n| `MONGO_URI` | Full connection URI (takes precedence if set) |\n| `MONGO_HOST` | Database host (used if `MONGO_URI` is not set) |\n| `MONGO_PORT` | Database port (default: `27017`) |\n| `MONGO_USER` | Username |\n| `MONGO_PASSWORD` | Password |\n| `MONGO_DB` | Specific database to back up (optional — backs up all if omitted) |\n\n### PostgreSQL\n\n| Variable | Description |\n|---|---|\n| `PG_HOST` | Database host |\n| `PG_PORT` | Database port |\n| `PG_USER` | Username (default: `root`) |\n| `PG_PASSWORD` | Password |\n| `AWS_REGION` | Required when `BACKUP_PROVIDER=aws` |\n\n### Redis\n\n| Variable | Description |\n|---|---|\n| `REDIS_HOST` | Redis host |\n| `REDIS_PORT` | Redis port (default: `6379`) |\n| `REDIS_PASSWORD` | Password (optional) |\n\nFor Redis **cluster mode**, the following are also required:\n\n| Variable | Description |\n|---|---|\n| `NUM_PRIMARIES` | Number of primary nodes in the cluster |\n| `REDIS_WORKLOAD_NAME` | Control Plane workload name for the Redis statefulset |\n| `CPLN_GVC` | Control Plane GVC name |\n| `CPLN_LOCATION` | Control Plane location |\n\n### TiDB\n\n| Variable | Description |\n|---|---|\n| `TIDB_PD_ADDR` | PD server address |\n| `AWS_REGION` | Required when `BACKUP_PROVIDER=aws` |\n\n---\n\n## Repository Structure\n\n```\nbackups/\n├── mongo-backup/\n│   ├── Dockerfile\n│   └── backup.sh\n├── mysql-backup/\n│   ├── Dockerfile\n│   └── backup.sh\n├── postgres-backup/\n│   ├── Dockerfile\n│   └── backup.sh\n├── redis-backup/\n│   ├── Dockerfile\n│   └── backup.sh\n└── tidb-backup/\n    ├── Dockerfile\n    └── backup.sh\n```\n\n---\n\n## Contributing\n\nPull requests are welcome. If you are fixing a bug or adding support for a new provider, please:\n\n1. Fork the repo and create a branch from `main`.\n2. Test your changes by building the image locally:\n   ```bash\n   docker build -t \u003cdb\u003e-backup:local ./\u003cdb\u003e-backup\n   ```\n3. Open a pull request with a clear description of the change.\n\n---\n\n## Documentation\n\nFull documentation for template backups, including how to configure cron jobs and cloud credentials in Control Plane, can be found at [docs.controlplane.com/template-catalog](https://docs.controlplane.com/template-catalog).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcontrolplane-com%2Fbackup-images","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcontrolplane-com%2Fbackup-images","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcontrolplane-com%2Fbackup-images/lists"}