feat(deploy-fly): implement real CLI-backed flyctl integration#228
feat(deploy-fly): implement real CLI-backed flyctl integration#228emil07770 wants to merge 1 commit into
Conversation
Replace stub with actual exec() calls to flyctl for both build and ship.
- build(): runs `flyctl deploy --build-only` with FLY_API_TOKEN env
- ship(): runs `flyctl deploy --remote-only --strategy=<strategy>` with token
- Reads token via ctx.secret('FLY_API_TOKEN'), throws if missing
- Short-circuits on ctx.dryRun in ship()
- Parses deployed URL from flyctl stdout (https://*.fly.dev)
- Passes cwd and env to exec for proper isolation
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
Heads up — the failing |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
18 similar comments
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
|
🤖 Auto-rebase: The branch was rebased successfully locally but could not be pushed to the fork. Please enable 'Allow edits from maintainers' in the PR settings, or rebase manually: |
Summary
build()andship()with realexec()calls toflyctlbuild(): runsflyctl deploy --build-only --app <app>withFLY_API_TOKENenv varship(): runsflyctl deploy --remote-only --strategy=<strategy> --app <app>with token; supports--regionflags and custom--dockerfilectx.secret('FLY_API_TOKEN'), throws descriptive error if missingctx.dryRuninship()https://*.fly.dev) and deployment version (v<n> deployed)cwd: ctx.projectDirandenv: { FLY_API_TOKEN }toexecfor proper isolationTest plan
FLY_API_TOKENsecret:sh1pt secret set FLY_API_TOKEN <token>sh1pt ship deploy-fly --dry-runshould return{ id: 'dry-run' }without calling flyctlsh1pt build deploy-flyshould invokeflyctl deploy --build-onlysh1pt ship deploy-flyshould invokeflyctl deploy --remote-only --strategy=rollingand return{ id, url }sh1pt secret set FLY_API_TOKEN🤖 Generated with Claude Code