Phase 6 part 2: restore from a backup
A restore is staged (checked, the current database backed up) and swapped in when the app next starts. Settings → Backups restores with a self-restart, cancels a waiting restore, and takes uploads; supermarket restore takes a backup name or a file; supermarket backup --with-secrets makes an archive with the keys, for moving machines. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -48,6 +48,7 @@ type Server struct {
|
||||
MCPToken string
|
||||
MCPSocket string // the MCP socket's path on the host, for Hermes' config
|
||||
MCP http.Handler
|
||||
Restart func() // stops the app so Docker starts it again; nil in tests
|
||||
Log *slog.Logger
|
||||
|
||||
// What the legacy import did at startup, or why it failed.
|
||||
@@ -233,6 +234,7 @@ func (s *Server) Handler() (http.Handler, error) {
|
||||
mux.HandleFunc("GET /settings/backups", s.backupsPage)
|
||||
mux.HandleFunc("POST /settings/backups/{action}", s.backupsAction)
|
||||
mux.HandleFunc("GET /settings/backups/file/{name}", s.backupDownload)
|
||||
mux.HandleFunc("POST /settings/backups/upload", s.backupUpload)
|
||||
mux.HandleFunc("GET /settings/core", s.corePage)
|
||||
mux.HandleFunc("GET /settings/core/checks", s.coreChecks)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user