-
Notifications
You must be signed in to change notification settings - Fork 0
feat(cli): add backup subcommands (backup, backup list, backup restore) #542
Copy link
Copy link
Closed
Labels
prio:mediumShould do, but not blockingShould do, but not blockingscope:smallLess than 1 day of workLess than 1 day of workspec:toolsDESIGN_SPEC Section 11 - Tool & Capability SystemDESIGN_SPEC Section 11 - Tool & Capability Systemtype:featureNew feature implementationNew feature implementation
Description
Summary
Add Go CLI backup subcommands to complement the Python API backup endpoints implemented in #449.
Motivation
Issue #449 acceptance criterion #4 requires "Manual backup via API and CLI". The API endpoints are fully implemented (PR #541), but the CLI subcommands were deferred as out of scope for that PR. This issue tracks the CLI portion.
CLI Commands
| Command | Description | Backend Endpoint |
|---|---|---|
synthorg backup |
Trigger manual backup | POST /api/v1/admin/backup |
synthorg backup list |
List available backups | GET /api/v1/admin/backups |
synthorg backup restore <id> |
Restore from backup | POST /api/v1/admin/restore |
Implementation Notes
- Add Cobra subcommands under
cli/cmd/ - Follow existing CLI patterns (e.g.,
start,stop,statuscommands) backup restoreshould stop running containers, call restore endpoint, restart- Display backup list in a formatted table (lipgloss styling)
- Include
--confirmflag for restore (safety gate)
Dependencies
- feat: implement automated backup and restore system #449 (backup API endpoints -- implemented in PR feat(backup): implement automated backup and restore system #541)
Acceptance Criteria
-
synthorg backuptriggers a manual backup and displays the manifest -
synthorg backup listshows available backups in a formatted table -
synthorg backup restore <id>restores from a backup with confirmation prompt - All commands handle errors gracefully with user-friendly messages
- Tests cover happy paths and error cases
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
prio:mediumShould do, but not blockingShould do, but not blockingscope:smallLess than 1 day of workLess than 1 day of workspec:toolsDESIGN_SPEC Section 11 - Tool & Capability SystemDESIGN_SPEC Section 11 - Tool & Capability Systemtype:featureNew feature implementationNew feature implementation