Skip to main content

CI/CD in Dagster+ Serverless

note

This guide only applies to Dagster+ Serverless deployments. For Hybrid guidance, see CI/CD in Dagster+ Hybrid.

If you're a GitHub or GitLab user, you can use our predefined workflows to deploy and synchronize your code to Dagster+ Serverless. You can also use other Git providers, or a local Git repository with the dagster-cloud CLI to run your own CI/CD process.

note

Using the Connect to GitHub or Connect to GitLab apps in Dagster+ to configure a Git repository requires the Organization Admin role so that the system can provision an agent token.

If you're a GitHub user, you can use our GitHub app with GitHub Actions to set up a repository containing basic code and configuration for you consistent with Dagster+ best practices.

Once you have set up the repo, pushing your code changes to the main branch will automatically deploy them to your prod Serverless full deployment. Pull requests will create ephemeral branch deployments that you can preview and test in the Dagster+ UI.

If you are importing a Dagster project in an existing GitHub repo
  • The repo will need to allow the Workflow permission for Read and write permissions. Workflow permissions settings can be found in GitHub's Settings > Actions > General > Workflow permissions. In GitHub Enterprise, these permissions are controlled at the Organization level.

  • An initial commit will need to be able to be merged directly to the repo's main branch to automatically add the GitHub Actions workflow files. If branch protection rules require changes be made through pull requests, this will prevent the automatic setup from completing. You can temporarily disable the branch protection rules and then re-enable them after the automatic setup completes.