Skip to main content

astro deployment update

info

The behavior and format of this command differs depending on what Astronomer product you're using. Use the following tabs to change product contexts.

Update the configuration for a Deployment on Astro.

info

To update existing worker queues or to create new queues for an existing Deployment, you must update your Deployment by using the --deployment-file flag to update a Deployment file.

Usage

astro deployment update <deployment-id> <flags>
tip

This command is recommended for automated workflows. To run this command in an automated process such as a CI/CD pipeline, you can generate an API token, then specify the ASTRO_API_TOKEN environment variable in the system running the Astro CLI:

export ASTRO_API_TOKEN=<your-token>

See Organization, Workspace, and Deployment API token documentation for more details about ways to use API tokens.

Options

OptionDescriptionPossible Values
--dag-deployEnable or disable DAG-only deploys for the Deployment.Either enable or disable. Contact Astronomer support before using disable to disable the feature.
--deployment-fileLocation of the Deployment file to update the Deployment with. The file format can be JSON or YAML. See Create a Deployment with a Deployment File.A valid file path to any YAML or JSON Deployment file
<deployment-id> (Required)The ID of the Deployment to updateAny valid Deployment ID
--deployment-nameThe name of the Deployment to update. Use as an alternative to <deployment-id>.Any valid Deployment name
-d,--descriptionThe description for the DeploymentAny string. Multiple-word descriptions should be specified in quotations (")
--cicd-enforcementSpecify that the Deployment can only accept code deploys from API tokens and keys. Note that in CLI versions before 1.23, this flag was --enforce-cicd.None
--default-task-pod-cpu(Astro Hosted only) The default task Pod CPUs to use for the Deployment. See Customize a task's Kubernetes Pod for more information.A numeric value such as 0.25. This number cannot exceed the values you configured in your Default pod resources in the UI or in your Deployment configuration file.
--default-task-pod-memory(Astro Hosted only) The default task pod memory to use for the Deployment in Gi. See Customize a task's Kubernetes Pod for more information.A numeric value followed by Gi, such as 0.5Gi. This number cannot exceed the values you configured in your Default pod resources in the UI or in your Deployment configuration file.
-e,--executorThe executor to use for the DeploymentCeleryExecutor or KubernetesExecutor
-f,--forceForce a Deployment updateNone
-l,--nameThe Deployment's nameAny string. Multiple-word descriptions should be specified in quotations
--resource-quota-cpu(Astro Hosted only) The Deployment's CPU resource quota for Kubernetes Pods. See Customize a task's Kubernetes Pod for more information.A numeric value such as 10. This number cannot exceed the values you configured in your Default pod resources in the UI or in your Deployment file configuration file.
--resource-quota-memory(Astro Hosted only) The Deployment's memory resource quota for Kubernetes Pods in Gi. See Customize a task's Kubernetes Pod for more information.A numeric value followed by Gi, such as 20Gi. This number cannot exceed the values you configured in your Default pod resources in the UI or in your Deployment file configuration file.
-s,--scheduler-auThe number of AU to allocate towards the Deployment's Scheduler(s). The default is5.Integer between 0 and 24
-r,--scheduler-replicasThe number of scheduler replicas for the Deployment. The default is 1.Integer between 0 and 4
-w,--workspace-idSpecify a Workspace to update a Deployment outside of your current WorkspaceAny valid Workspace ID

Examples

# Update a Deployment's name and description
$ astro deployment update cl03oiq7d80402nwn7fsl3dmv -d="My Deployment Description" --name="My Deployment Name"

# Force update a Deployment
$ astro deployment update cl03oiq7d80402nwn7fsl3dmv -d="My Deployment Description" --force

# Update the Deployment according to the configurations specified in the YAML Deployment file
$ astro deployment update --deployment-file deployment.yaml

Was this page helpful?

Sign up for Developer Updates

Get a summary of new Astro features once a month.

You can unsubscribe at any time.
By proceeding you agree to our Privacy Policy, our Website Terms and to receive emails from Astronomer.