From 75d650986bee520168ba37fdb057fa8990994141 Mon Sep 17 00:00:00 2001 From: Ly Nguyen Date: Thu, 18 Apr 2024 15:23:38 -0700 Subject: [PATCH 1/4] Fast-follows for merge jobs --- website/docs/docs/deploy/merge-jobs.md | 2 ++ website/docs/guides/custom-cicd-pipelines.md | 8 +++++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/website/docs/docs/deploy/merge-jobs.md b/website/docs/docs/deploy/merge-jobs.md index 52fea5c18e6..53e87061f5c 100644 --- a/website/docs/docs/deploy/merge-jobs.md +++ b/website/docs/docs/deploy/merge-jobs.md @@ -13,6 +13,8 @@ By using CD in dbt Cloud, you can take advantage of deferral to build only the e ## Prerequisites - You have a dbt Cloud account. - You have access to the beta release for this functionality. +- You have set up a [connection with your Git provider](/docs/cloud/git/git-configuration-in-dbt-cloud). This integration lets dbt Cloud run jobs on your behalf for job triggering. + - If you're using a native [GitLab](/docs/cloud/git/connect-gitlab) integration, you need a paid or self-hosted account that includes support for GitLab webhooks and [project access tokens](https://docs.gitlab.com/ee/user/project/settings/project_access_tokens.html). If you're using GitLab Free, merge requests will trigger CI jobs but CI job status updates (success or failure of the job) will not be reported back to GitLab. ## Set up job trigger on Git merge {#set-up-merge-jobs} diff --git a/website/docs/guides/custom-cicd-pipelines.md b/website/docs/guides/custom-cicd-pipelines.md index bb22b5fb944..bff90e923f3 100644 --- a/website/docs/guides/custom-cicd-pipelines.md +++ b/website/docs/guides/custom-cicd-pipelines.md @@ -58,6 +58,12 @@ Here’s a quick look at what this pipeline will accomplish: This job will take a bit more to setup, but is a good example of how to call the dbt Cloud API from a CI/CD pipeline. The concepts presented here can be generalized and used in whatever way best suits your use case. +:::tip Run on merge + +If your Git provider has a native integration with dbt Cloud, you can take advantage of setting up [Merge jobs](/docs/deploy/merge-jobs) in the UI. + +::: + The setup below shows how to call the dbt Cloud API to run a job every time there's a push to your main branch (The branch where pull requests are typically merged. Commonly referred to as the main, primary, or master branch, but can be named differently). ### 1. Get your dbt Cloud API key @@ -509,7 +515,7 @@ Additionally, you’ll see the job in the run history of dbt Cloud. It should be If your git provider is not one with a native integration with dbt Cloud, but you still want to take advantage of CI builds, you've come to the right spot! With just a bit of work it's possible to setup a job that will run a dbt Cloud job when a pull request (PR) is created. -:::info Run on PR +:::tip Run on PR If your git provider has a native integration with dbt Cloud, you can take advantage of the setup instructions [here](/docs/deploy/ci-jobs). This section is only for those projects that connect to their git repository using an SSH key. From 6c8501326a233cc201ddd7da7192039db64867b8 Mon Sep 17 00:00:00 2001 From: Ly Nguyen Date: Thu, 18 Apr 2024 15:31:57 -0700 Subject: [PATCH 2/4] Remove beta refs --- website/docs/docs/deploy/merge-jobs.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/website/docs/docs/deploy/merge-jobs.md b/website/docs/docs/deploy/merge-jobs.md index 53e87061f5c..720adfd1005 100644 --- a/website/docs/docs/deploy/merge-jobs.md +++ b/website/docs/docs/deploy/merge-jobs.md @@ -4,7 +4,7 @@ sidebar_label: "Merge jobs" description: "Learn how to trigger a dbt job run when a Git pull request merges." --- -# Merge jobs in dbt Cloud +# Merge jobs in dbt Cloud You can set up a merge job to implement a continuous development (CD) workflow in dbt Cloud. The merge job triggers a dbt job to run when someone merges Git pull requests into production. This creates a seamless development experience where changes made in code will automatically update production data. @@ -12,7 +12,6 @@ By using CD in dbt Cloud, you can take advantage of deferral to build only the e ## Prerequisites - You have a dbt Cloud account. -- You have access to the beta release for this functionality. - You have set up a [connection with your Git provider](/docs/cloud/git/git-configuration-in-dbt-cloud). This integration lets dbt Cloud run jobs on your behalf for job triggering. - If you're using a native [GitLab](/docs/cloud/git/connect-gitlab) integration, you need a paid or self-hosted account that includes support for GitLab webhooks and [project access tokens](https://docs.gitlab.com/ee/user/project/settings/project_access_tokens.html). If you're using GitLab Free, merge requests will trigger CI jobs but CI job status updates (success or failure of the job) will not be reported back to GitLab. From 08857c30bab2cc4e953a47160219c17a148c5fbd Mon Sep 17 00:00:00 2001 From: Ly Nguyen <107218380+nghi-ly@users.noreply.github.com> Date: Thu, 18 Apr 2024 15:33:04 -0700 Subject: [PATCH 3/4] Update website/docs/docs/deploy/merge-jobs.md --- website/docs/docs/deploy/merge-jobs.md | 1 - 1 file changed, 1 deletion(-) diff --git a/website/docs/docs/deploy/merge-jobs.md b/website/docs/docs/deploy/merge-jobs.md index 720adfd1005..0b6763c5373 100644 --- a/website/docs/docs/deploy/merge-jobs.md +++ b/website/docs/docs/deploy/merge-jobs.md @@ -4,7 +4,6 @@ sidebar_label: "Merge jobs" description: "Learn how to trigger a dbt job run when a Git pull request merges." --- -# Merge jobs in dbt Cloud You can set up a merge job to implement a continuous development (CD) workflow in dbt Cloud. The merge job triggers a dbt job to run when someone merges Git pull requests into production. This creates a seamless development experience where changes made in code will automatically update production data. From fd6b5d786cc64d584586254962e251d26d98cb21 Mon Sep 17 00:00:00 2001 From: Ly Nguyen Date: Mon, 22 Apr 2024 08:50:25 -0700 Subject: [PATCH 4/4] Feedback --- website/docs/docs/deploy/merge-jobs.md | 1 + 1 file changed, 1 insertion(+) diff --git a/website/docs/docs/deploy/merge-jobs.md b/website/docs/docs/deploy/merge-jobs.md index 720adfd1005..b2f860536de 100644 --- a/website/docs/docs/deploy/merge-jobs.md +++ b/website/docs/docs/deploy/merge-jobs.md @@ -14,6 +14,7 @@ By using CD in dbt Cloud, you can take advantage of deferral to build only the e - You have a dbt Cloud account. - You have set up a [connection with your Git provider](/docs/cloud/git/git-configuration-in-dbt-cloud). This integration lets dbt Cloud run jobs on your behalf for job triggering. - If you're using a native [GitLab](/docs/cloud/git/connect-gitlab) integration, you need a paid or self-hosted account that includes support for GitLab webhooks and [project access tokens](https://docs.gitlab.com/ee/user/project/settings/project_access_tokens.html). If you're using GitLab Free, merge requests will trigger CI jobs but CI job status updates (success or failure of the job) will not be reported back to GitLab. +- You are set up to receive push notifications from your Git provider. For details, refer to [Job notifications](/docs/deploy/job-notifications). ## Set up job trigger on Git merge {#set-up-merge-jobs}