Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New env variables #6014

Merged
merged 7 commits into from
Sep 20, 2024
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 9 additions & 6 deletions website/docs/docs/build/environment-variables.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ While all environment variables are encrypted at rest in dbt Cloud, dbt Cloud ha

dbt Cloud has a number of pre-defined variables built in. Variables are set automatically and cannot be changed.

**dbt Cloud IDE details**
#### dbt Cloud IDE details

The following environment variable is set automatically for the dbt Cloud IDE:

Expand All @@ -109,13 +109,16 @@ The following environment variable is set automatically for the dbt Cloud IDE:

Use case — This is useful in cases where you want to dynamically use the Git branch name as a prefix for a [development schema](/docs/build/custom-schemas) ( `{{ env_var ('DBT_CLOUD_GIT_BRANCH') }}` ).

**dbt Cloud context**
#### dbt Cloud context

The following environment variables are set automatically for deployment runs:
The following environment variables are set automatically:

- `DBT_ENV`: This key is reserved for the dbt Cloud application and will always resolve to 'prod'
- `DBT_ENV`: This key is reserved for the dbt Cloud application and will always resolve to 'prod' (for deployment runs only).
matthewshaver marked this conversation as resolved.
Show resolved Hide resolved
- `DBT_CLOUD_ENVIRONMENT_NAME`: The name of the dbt Cloud environment in which `dbt`is running.
matthewshaver marked this conversation as resolved.
Show resolved Hide resolved
- `DBT_CLOUD_ENVIRONMENT_TYPE`: The type of dbt Cloud environment in which `dbt` is running. The values are `development` or `deployment`.
matthewshaver marked this conversation as resolved.
Show resolved Hide resolved

#### Run details

**Run details**
- `DBT_CLOUD_PROJECT_ID`: The ID of the dbt Cloud Project for this run
- `DBT_CLOUD_JOB_ID`: The ID of the dbt Cloud Job for this run
- `DBT_CLOUD_RUN_ID`: The ID of this particular run
Expand All @@ -124,7 +127,7 @@ The following environment variables are set automatically for deployment runs:
- `DBT_CLOUD_ENVIRONMENT_ID`: The ID of the environment for this run
- `DBT_CLOUD_ACCOUNT_ID`: The ID of the dbt Cloud account for this run

**Git details**
#### Git details

_The following variables are currently only available for GitHub, GitLab, and Azure DevOps PR builds triggered via a webhook_

Expand Down
2 changes: 2 additions & 0 deletions website/docs/docs/dbt-versions/release-notes.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ Release notes are grouped by month for both multi-tenant and virtual private clo
\* The official release date for this new format of release notes is May 15th, 2024. Historical release notes for prior dates may not reflect all available features released earlier this year or their tenancy availability.

## August 2024

- **New:** There are two new [environment variable defaults](/docs/build/environment-variables#dbt-cloud-context) — `DBT_CLOUD_ENVIRONMENT_NAME` and `DBT_CLOUD_ENVIRONMENT_TYPE`.
matthewshaver marked this conversation as resolved.
Show resolved Hide resolved
- **Behavior change:** GitHub is no longer supported for OAuth login to dbt Cloud. Use a supported [SSO or OAuth provider](/docs/cloud/manage-access/sso-overview) to securely manage access to your dbt Cloud account.
- **New**: You can now configure metrics at granularities at finer time grains, such as hour, minute, or even by the second. This is particularly useful for more detailed analysis and for datasets where high-resolution time data is required, such as minute-by-minute event tracking. Refer to [dimensions](/docs/build/dimensions) for more information about time granularity.

Expand Down
Loading