Repository navigation
feat: add ephemeral-environment list, view and delete commands - #754
Draft
justin-newman wants to merge 4 commits into
Draft
justin-newman wants to merge 4 commits into
justin-newman wants to merge 4 commits into
Conversation
Contributor
Author
|
@NickJosevski for your consideration |
view shows the provisioning status of an ephemeral environment for a project, and delete removes an ephemeral environment directly (for example when provisioning failed and it cannot be deprovisioned). Both use the new GetStatus and Delete functions in go-octopusdeploy.
list shows the ephemeral environments in a space. With --project it also shows the provisioning status of each environment for that project, since the status is per project. A failure to read one status is reported and shown as Unknown rather than stopping the listing.
justin-newman
force-pushed
the
kepler/issue-753-ephemeral-environment-status-delete
branch
from
October 15, 2026 17:01
0488402 to
82f8aa9
Compare
Expect the name query parameter the updated client sends, and serve the client's initial requests in the tests that validate missing flags so they no longer block.
The updated go-octopusdeploy client includes an empty name parameter on ephemeral environment lookups. Update the mocked request URLs in the tests that hard-code them, so they pass once go.mod is bumped.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #753
Blocked on go-octopusdeploy
This depends on OctopusDeploy/go-octopusdeploy#489, which adds
ephemeralenvironments.GetStatusandDelete. It can't merge until that PR is merged and released andgo.modis bumped here. It won't build against the currently pinned client, so it's a draft until then.Changes
ephemeral-environment listlists the ephemeral environments in the space. With--projectit adds a STATUS column, since the provisioning status is per project. If the status of one environment can't be read it is reported on stderr and shown asUnknown, and the rest of the list still prints.ephemeral-environment view --name <name> --project <project>shows the provisioning status of an environment for a project. Supports table, basic and--output-format json.ephemeral-environment delete --name <name>deletes an ephemeral environment directly, for cases where it can't be deprovisioned (for exampleProvisioningFailed). It confirms by name unless--confirmis passed.Not included
I considered an ephemeral fallback in
environment delete(and accepting an ID there) and decided against it. I don't think a fallback is as safe for a delete command: a name that matches nothing in the classic list could silently resolve to a different, ephemeral resource. A dedicatedephemeral-environment deletemakes the target explicit. Happy to revisit if there's demand.