Repository navigation
Description
What
charly remove --keep-deploy keeps the deploy entry (so resolved_port survives) but the deployment cannot be started again from it — start needs the resolved plan/unit that remove deleted:
$ charly remove strata -i scratch989 --keep-deploy
Removed …/charly-strata-scratch989.container
$ charly start strata -i scratch989
charly: error: command "start": deploy-dispatch start: deploy plugin: InvokeProvider deploy:pod op=start:
rpc error: code = Unknown desc = plugin-deploy-pod start: resolve plan: not configured;
run 'charly config strata' firstand the deploy entry IS still there after the keep-deploy remove (5 lines in ~/.config/charly/charly.yml), so it is not a lost configuration — it is a lost plan/unit.
Why it matters
The operator-facing requirement is "a pod rebuild must not lose the published port". Today the only recovery is charly config again — and charly config without -p assigns a NEW random host port, which is exactly how a deployment silently moved from 36201 to 45635. So --keep-deploy preserves the data but not the ability to use it.
Measured sequence (host a, charly 2026.293.1230 + the plugin-pod patch from #17)
$ charly config strata -i scratch989 --tag 2026.292.2207 -p 36299:8080 -v …
$ grep PublishPort ~/.config/containers/systemd/charly-strata-scratch989.container
PublishPort=127.0.0.1:36299:8080
$ charly remove strata -i scratch989 --keep-deploy
$ grep -c scratch989 ~/.config/charly/charly.yml
5 # the entry, with resolved_port, survived
$ charly start strata -i scratch989
resolve plan: not configured; run 'charly config strata' firstRoot fix (options, in preference order)
remove --keep-deployalso keeps (or regenerates) the quadlet/plan, sostartworks and the port is preserved end to end.- Or
charly configdefaults the port to the one recorded in the existing deploy entry instead of allocating a new random port when-pis omitted. - At minimum,
startshould say "the deploy entry exists but its plan does not — re-runcharly config, and pass-pto keep the current port" rather than only "not configured".
Related
- charly remove silently drops the published host port (service comes back on a random port) charly#989 — the silent-discard half, fixed by fix(remove): say what the deploy entry carries before discarding it (closes #989) #17 (that patch now prints what the entry carried; it does not claim to fix this).
- charly remove silently drops the published host port (service comes back on a random port) charly#989 measured the symptom (random 45635 instead of 36201); this issue is the mechanism behind it.
Assisted-by: DeepSeek Harness deepseek-v4.1-flash (analysed on a live system)
Activity
fix(remove): report the deploy-entry discard from the call site, and …
fix(remove): --keep-deploy keeps the sidecar units too
fix(remove): report what the deploy entry carries, and make --keep-de…