uselagoon / uselagoon/lagoon-cli

Cancel deployment from CLI

Open
#411 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Go
Stars
28
Forks
14
Avg merge
1d 2h
Merged PRs (30d)
1

Description

Is your feature request related to a problem? Please describe.

For some of our projects, we need to set some environment variables at environment level before the first deployment. Creating an environment without starting a deployment currently is not possible.

If we are able to cancel a deployment, we could start a deployment and directly cancel the deployment to create an environment in lagoon without actually deploying it. This allows us to set the correct environment variables (via CI / CLI) and then start a new correct deployment

Describe the solution you'd like

  1. Be able to create an environment without directly deploying to it, to be able to set environment variables for the environment
  2. Cancel a deployment by its identifier

Describe alternatives you've considered

  1. Start the new environment with a deployment and directly cancel the deployment
  2. Set the environment specific variables as environment variables at project level and remove after the environment has been created
  3. Start a build using lagoon deploy branch --project {PROJECT} --branch {ENVIRONMENT_NAME} --branch-ref NONEXISTENTHASH if the environment does not exist, so the first build will fail at stage Checkout Repository

Additional context
N/A

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the CLI's lagoon deploy branch command and trace how it creates deployments and handles deployment identifiers. Done means the CLI can cancel a deployment by identifier and support creating an environment without completing its initial deployment, covering both requested workflows.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
cli
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.