Skip to main content
To rotate a credential in Astro, first identify whether it’s stored at the Workspace level or the Deployment level. At either level, it can be an environment variable, a connection, or an Airflow variable. For background on how Astro stores these values, see Secrets management.

Workspace-level credentials

In the Astro UI, go to Environment and select Environment Variables, Connections, or Airflow Variables. When you update a Workspace-level value, the change applies to all linked Deployments and finishes updating within a few minutes.
If a linked Deployment has a value override, it keeps its override value. To rotate the credential for those Deployments, update the link as well. See the last step of each procedure below.

Environment variables

1

Edit the environment variable

Open the More actions menu (⋯) next to the environment variable, then click Edit Environment Variable.
The More actions menu for an environment variable with the Edit Environment Variable option highlighted
2

Enter the new value

In the Environment Variable Value field, enter the newly generated value for your credential, then click Update Environment Variable.
The Edit Environment Variable dialog showing the Environment Variable Value field
3

Update linked Deployments with overrides

Click the environment variable to see all linked Deployments.
The environment variable details page with the Linked Deployments tab selected
For each Deployment that has an override, open the More actions menu (⋯), then click Edit Link.
The More actions menu for a linked Deployment with the Edit Link option highlighted
Enter the new value in the Value field, then click Update Environment Variable Link.
The Edit Environment Variable link to Deployment dialog showing the override Value field

Connections

1

Edit the connection

Open the More actions menu (⋯) next to the connection, then click Edit Connection.
The More actions menu for a connection with the Edit Connection option highlighted
2

Enter the new values

Enter the newly generated values for your credential in their respective fields, then click Update Connection.
The Edit Generic Connection dialog showing the connection fields
The fields in this dialog differ depending on the connection type.
3

Update linked Deployments with overrides

Click the connection to see all linked Deployments.
The connection details page with the Linked Deployments tab selected
For each Deployment that has an override, open the More actions menu (⋯), then click Edit Link. Enter the new values in their respective fields, then click Update Connection Link.
The Edit Connection link to Deployment dialog showing the override fields

Airflow variables

1

Edit the Airflow variable

Open the More actions menu (⋯) next to the Airflow variable, then click Edit Airflow Variable.
The More actions menu for an Airflow variable with the Edit Airflow Variable option highlighted
2

Enter the new value

In the Airflow Variable Value field, enter the newly generated value for your credential, then click Update Airflow Variable.
The Edit Airflow Variable dialog showing the Airflow Variable Value field
3

Update linked Deployments with overrides

Click the Airflow variable to see all linked Deployments.
The Airflow variable details page with the Linked Deployments tab selected
For each Deployment that has an override, open the More actions menu (⋯), then click Edit Link. Enter the new value in the Value field, then click Update Airflow Variable Link.
The Edit Airflow Variable link to Deployment dialog showing the override Value field

Deployment-level credentials

In the Astro UI, click Deployments, select a Deployment, then click the Environment tab.
The Environment tab of a Deployment, with sub-tabs for Environment Variables, Connections, and Airflow Variables
When you update a Deployment-level value, the change is deployed to that Deployment and finishes updating within a few minutes.

Environment variables

1

Edit the environment variables

Click Edit Deployment Variables.
The Environment Variables sub-tab of a Deployment with the Edit Deployment Variables button
2

Enter the new value

In the dialog, enter the newly generated value for your credential next to its key, then click Update Environment Variables.
The Edit Environment Variables dialog listing each key, value, and source

Connections

1

Edit the connection

Open the More actions menu (⋯) next to the connection, then click Edit Connection.
The More actions menu for a Deployment connection with the Edit Connection option
2

Enter the new values

Enter the newly generated values for your credential in their respective fields, then click Update Connection.
The Edit Generic Connection dialog showing the connection fields
The fields in this dialog differ depending on the connection type.

Airflow variables

1

Edit the Airflow variable

Open the More actions menu (⋯) next to the Airflow variable, then click Edit Airflow Variable.
The Airflow Variables sub-tab of a Deployment listing each variable with a More actions menu
2

Enter the new value

In the Airflow Variable Value field, enter the newly generated value for your credential, then click Update Airflow Variable.
The Edit Airflow Variable dialog showing the Airflow Variable Value field