GitHub Action templates use the Astronomer-maintained deploy-action, which is available in the GitHub Marketplace. This action automates the deploy process and includes additional features for more complex automation workflows. Specifically, the action can automatically:
tests directory of your Astro project.inferimage-and-dagsimage-onlydags-onlydbtIf you have one Deployment and one environment on Astro, use the single branch implementation. If you have multiple Deployments that support development and production environments, use the multiple branch implementation. If your team builds custom Docker images, use the custom image implementation. If you don’t have access to Astronomer’s deploy-action, use the private network templates.
To learn more about CI/CD on Astro, see Choose a CI/CD strategy.
The deploy-action includes several deploy types for you to choose a specific type of code deploy for your CI/CD processes.
By default, the deploy-action uses infer, which allows it to determine the type of code deploy to use based on the types of files changed in a commit: Dag or Astro project. If you committed changes only to dag files, the action triggers a dag deploy. If you committed changes to any other file, the action triggers an image deploy, or image-and-dags. This setting does not include dbt deploy types. See default deploy action.
The image-and-dags option enables the Deploy Action to make a full project deploy, which includes both images and dags. This option will also include code in includes/, plugins/, or any other directories in the root of the repository. For example, if you have a dbt project in a dbt/ directory, it will be included when using this Deploy Action.
The image-only option enables the Deploy Action to deploy only the Docker image of your Astro project without updating existing dags on your Deployment. Use this option when you want to push dependency or configuration changes independently of your dag code. This deploy type skips dag parsing and pytest validation. Requires Astro CLI version 1.21.0 or later.
The dags-only deploy option enables the deploy action to deploy only the dags in your Astro project’s dags directory to your Deployment.
The dbt deploy option enables the Deploy Action to deploy dbt projects to Astro, when you provide the path to a directory in your GitHub repo that contains your dbt project. See dbt deploy action. This is most commonly used when your dbt code/logic does not live in the same repository as your Astro project.