Add sc start and sc stop, and show deployment state in sc apps #24
No reviewers
Labels
No labels
⏳in-progress
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
Grey.ooo/someones.computer_agent!24
Loading…
Reference in a new issue
No description provided.
Delete branch "feature/start-stop-verbs"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
The CLI half of the tray story:
scgrows the two switch verbs, andsc appssays what state each deployment is in. Needs scclient #2 (pinned here as a pseudo-version and vendored) and the platform's listing change.sc start/sc stopBoth address a deployment by name, resolved exactly as
deployresolves it — positional argument, thendeployment:in.sc.yml, then the slugified branch — so switching the branch you are standing on off and back on takes no arguments:Nothing is uploaded and nothing is rebuilt: stop leaves the images in the registry, start puts the same ones back up.
startfollows what it dispatched. The platform answers202"queued", and the question a person asked is "is it up?" — so unless--detach, it attaches to the same progress streamsc deploywatches and exits non-zero unless the revision reachedrunning.A refused start says where to go. Activation is credit-gated, so a
402prints the balance and the billing page rather than just the refusal.sc appsEach deployment row now carries the status of the revision speaking for it, and that revision's number:
Verified
Against a live platform dev stack — the transcript in the platform PR is this binary.
go build,go vet,gofmt,go test ./...clean, vendored (GOWORK=off go test ./...passes offline, which is what CI runs). Newtoggle_test.gocovers accepted/detached, following to success, following to failure, the 402 with its balance, an ordinary 409, an ambiguous slug, a platform too old for the route, and a missing token.sc startandsc stop, and show each deployment's state insc appsWIP: Add sc start and sc stop, and show deployment state in sc appsto Add sc start and sc stop, and show deployment state in sc apps