feat: add Neo4j and CouchDB backup/restore support#471
Open
IronAlloy wants to merge 4 commits intonfrastack:mainfrom
Open
feat: add Neo4j and CouchDB backup/restore support#471IronAlloy wants to merge 4 commits intonfrastack:mainfrom
IronAlloy wants to merge 4 commits intonfrastack:mainfrom
Conversation
…README and .gitignore
The upstream workflow required DockerHub secrets that aren't set on this
fork, blocking builds. Replace with standalone workflows that push
multi-arch images to ghcr.io/${{ github.repository }} using only the
built-in GITHUB_TOKEN, so builds succeed without external credentials.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Collaborator
|
Thanks for your work. Going to leave open for now until I am ready to release the Nfrastack variant of this image. |
…tion and user prompts
latest-* backup files have no extension, causing the compression detection case-statement to fall through and leave decompress_cmd unset. Plain cat then piped raw compressed bytes into jq/the DB client, producing invalid UTF-8 / parse errors and a zero-document restore. Fix: resolve symlinks before extension sniffing, and fall back to `file --brief --mime-type` magic-byte detection when no recognizable extension is found. Applies to all DB types (MySQL, Postgres, MongoDB, Neo4j, CouchDB, Redis). Also adds rdbtools/python-lzf to the image for Redis RDB restore support. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds backup and restore support for Neo4j and CouchDB, rebased onto the latest
main(4.1.100). This supersedes #448 which only covered Neo4j.Neo4j
cypher-shellusingapoc.export.cypher.all()→.cypherfilescypher-shellquerycypher-shellinstalled from Neo4j community edition (NEO4J_VERSION=5.26.0)CouchDB
The project previously had skeletal CouchDB support (type detection + availability check), but
backup_couch()was missing the actual backup command, and there was no restore support.curl+_all_docs?include_docs=true) — no client binary neededDB_NAME=ALLto enumerate all non-system databases via_all_dbsDB_NAMElistDB_NAME_EXCLUDEwhen usingALL_) filtered automatically.jsonextension)_revfrom documents viajq, posts via_bulk_docsbackup_job_backup_job_db_port→backup_job_db_port(double prefix bug in the CouchDB bootstrap case)jqto runtime dependencies (needed for restore)DB_NAME/DB_NAME_EXCLUDEfor CouchDB in the READMETest plan
DB_NAME=testdbDB_NAME=ALL(system DBs excluded)DB_NAME=ALL+DB_NAME_EXCLUDE=somedbCloses #448