Add

Learn how to create a deployment.

Command

$ vela add deployment <parameters...> <arguments...>

Parameters

The following parameters are used to configure the command:

NameDescriptionEnvironment Variables
orgname of organization for the deploymentVELA_ORG, DEPLOYMENT_ORG
reponame of repository for the deploymentVELA_REPO, DEPLOYMENT_REPO
refname of branch, commit, or tag for the deploymentVELA_DEPLOYMENT, DEPLOYMENT_NUMBER
targetname of target environment for the deploymentVELA_TARGET, DEPLOYMENT_TARGET
descriptionshort description for the deploymentVELA_DESCRIPTION, DEPLOYMENT_DESCRIPTION
parameterparameter(s) in key=value format for the deploymentVELA_PARAMETERS,, DEPLOYMENT_PARAMETERS
taskname of task for the deploymentVELA_TASK, DEPLOYMENT_TASK
outputformat the output for the deploymentVELA_OUTPUT, DEPLOYMENT_OUTPUT

Sample

Request

$ pwd
~/github/octocat
$ vela add deployment

Targeted Request

$ vela add deployment --org github --repo octocat

Response generated from successful CLI command

deployment "https://api.github.com/repos/github/octocat/deployments/1" was created

Examples

EXAMPLES:
  1. Add a deployment for a repository.
    $ vela add deployment --org MyOrg --repo MyRepo
  2. Add a deployment for a repository with a specific target environment.
    $ vela add deployment --org MyOrg --repo MyRepo --target stage
  3. Add a deployment for a repository with a specific branch reference.
    $ vela add deployment --org MyOrg --repo MyRepo --ref dev
  4. Add a deployment for a repository with a specific commit reference.
    $ vela add deployment --org MyOrg --repo MyRepo --ref 48afb5bdc41ad69bf22588491333f7cf71135163
  5. Add a deployment for a repository with a specific tag.
    $ vela add deployment --org MyOrg --repo MyRepo --ref 'refs/tags/example.tag'
  6. Add a deployment for a repository with a specific description.
    $ vela add deployment --org MyOrg --repo MyRepo --description 'my custom message'
  7. Add a deployment for a repository with two parameters.
    $ vela add deployment --org MyOrg --repo MyRepo --parameter 'key=value' --parameter 'foo=bar'
  8. Add a deployment for a repository when config or environment variables are set.
    $ vela add deployment