Skip to content

fix: scope shellQuote and use --storage-deploy-mounts#2

Merged
guess merged 1 commit into
mainfrom
fix/ssh-quoting-and-storage-flag
Apr 28, 2026
Merged

fix: scope shellQuote and use --storage-deploy-mounts#2
guess merged 1 commit into
mainfrom
fix/ssh-quoting-and-storage-flag

Conversation

@guess

@guess guess commented Apr 28, 2026

Copy link
Copy Markdown
Owner

Summary

  • Two reconcile bugs were causing dry-run to fire commands whose target state already matched the server.
  • SSH arg quoting: shellQuote was wrapping every SSH arg in single quotes. dokku 0.36's SSH command wrapper handles literal-quoted args inconsistently — git:report failed (so reads returned empty and every app looked unconfigured every run) while ports:report happened to pass through. Quote only args containing shell-significant characters; plain identifiers and flags reach the remote unmodified.
  • Storage flag: Storage.read used --storage-mounts, which isn't a valid dokku flag (real flags are --storage-build-mounts, --storage-deploy-mounts, --storage-run-mounts). Reads returned empty, so every mount looked missing on every run. Switched to --storage-deploy-mounts and added a parser for the -v PATH:PATH -v PATH:PATH line format dokku reports.

Test plan

  • bun test — 215 tests pass (added 2 dokku.ts tests covering the new shellQuote behavior; updated lists.test.ts for the new storage parser)
  • Verified live on a dokku 0.36.10 server with DOKKU_HOST=localhost: prior to the fix every app reported git... done and qultr-sandbox storage... done; after the fix both report already configured and the corresponding commands no longer appear in the # Commands that would run: section

Two reconcile bugs causing dry-run to repeatedly fire commands whose
target state already matches the server.

shellQuote was wrapping every SSH arg in single quotes. dokku 0.36's
SSH command wrapper handles literal-quoted args inconsistently across
subcommands — git:report failed (so reads returned empty and every app
looked unconfigured) while ports:report happened to pass through. Quote
only args containing shell-significant characters; plain identifiers and
flags reach the remote unmodified.

Storage.read used --storage-mounts, which is not a valid dokku flag
(real flags are --storage-build-mounts, --storage-deploy-mounts,
--storage-run-mounts). Reads returned empty, so every mount looked
missing on every run. Switched to --storage-deploy-mounts and added a
parser for the "-v PATH:PATH -v PATH:PATH" line format dokku reports.
@guess
guess merged commit 004c2c3 into main Apr 28, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant