gcloud workflows deploy - create or update a workflow
gcloud workflows deploy (WORKFLOW : --location=LOCATION) [--async] [--description=DESCRIPTION] [--labels=[KEY=VALUE,...]] [--service-account=SERVICE_ACCOUNT] [--source=SOURCE] [GCLOUD_WIDE_FLAG ...]
Create or update a workflow.
To deploy a workflow with source code myWorkflow.yaml on Workflows:
$ gcloud workflows deploy my-workflow --source=myWorkflow.yaml
You may also skip waiting for the operation to finish:
$ gcloud workflows deploy my-workflow --source=myWorkflow.yaml \ --async
To specify a service account as the workflow identity:
$ gcloud workflows deploy my-workflow --source=myWorkflow.yaml \ --service-account=my-account@my-project.iam.gserviceaccount.com
- Workflow resource - Name of the workflow to deploy. The arguments in this group
can be used to specify the attributes of this resource. (NOTE) Some attributes are not given arguments in this group but can be set in other ways. To set the project attribute:
- —
provide the argument workflow on the command line with a fully specified name;
- —
provide the argument --project on the command line;
- —
set the property core/project.
This must be specified.
- WORKFLOW
ID of the workflow or fully qualified identifier for the workflow. To set the workflow attribute:
provide the argument workflow on the command line.
This positional argument must be specified if any of the other arguments in this group are specified.
- --location=LOCATION
Cloud location for the workflow. Alternatively, set the property [workflows/location]. To set the location attribute:
provide the argument workflow on the command line with a fully specified name;
provide the argument --location on the command line;
set the property workflows/location.
- --async
Return immediately, without waiting for the operation in progress to complete.
- --description=DESCRIPTION
The description of the workflow to deploy.
- --labels=[KEY=VALUE,...]
List of label KEY=VALUE pairs to add.
Keys must start with a lowercase character and contain only hyphens (-), underscores (_), lowercase characters, and numbers. Values must contain only hyphens (-), underscores (_), lowercase characters, and numbers.
- --service-account=SERVICE_ACCOUNT
The service account that should be used as the workflow identity. "projects/PROJECT_ID/serviceAccounts/" prefix may be skipped from the full resource name, in that case "projects/-/serviceAccounts/" is prepended to the service account ID.
- --source=SOURCE
Location of a workflow source code to deploy. Required on first deployment. Location needs to be defined as a path to a local file with the source code.
These flags are available to all commands: --access-token-file, --account, --billing-project, --configuration, --flags-file, --flatten, --format, --help, --impersonate-service-account, --log-http, --project, --quiet, --trace-token, --user-output-enabled, --verbosity.
Run $ gcloud help for details.
This variant is also available:
$ gcloud beta workflows deploy