feat: add a panel button to update the manager itself

The manager clones SELF_UPDATE_REPO_URL, builds a new image in the shared build queue and
hands over to a short-lived updater container (new image) that swaps the manager container,
health-checks it and rolls back on failure. Exposed as GET/POST /api/system behind requireAuth;
installation changes answer 409 while an update runs. Session cookie is now SameSite=Lax.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
dasemuandClaude Sonnet 5.5 committed 2026-10-19 05:45:25 +02:00
1 parent 5fb1d6b0b4
commit 4b3c8f213a
23 files changed
+705 -5

No files matched your search

+7
View File
@@ -40,6 +40,13 @@ MAX_PROXY_REQUESTS=100
# The manager exits (and is restarted by compose) when its heap + external memory passes this. 0 disables.
MANAGER_MEMORY_LIMIT_MB=512
# Enables the panel's "Update manager" button: the manager clones this repo at SELF_UPDATE_REF,
# builds a new image and replaces its own container (rolls back if the new one isn't healthy).
# Operator-set only, never taken from a request. Leave empty to disable the button.
# Needs SSH_DIR below if the URL is ssh://. See docs/operations.md.
SELF_UPDATE_REPO_URL=
SELF_UPDATE_REF=master
# Absolute path to an SSH dir (key + known_hosts) with clone access to the repos you'll
# install, mounted read-only into the manager container so `git clone ssh://...` works for
# private repos. Required only if you install from private/SSH repo URLs.