Skip to content

mojafa/template-dbt-snowflake

 
 

Repository files navigation

A dbt template on Gitpod

This is a dbt template configured for ephemeral cloud development environments on Gitpod. The project is based on the famous jaffle_shop example.

Connecting to Snowflake

Before you can connect to Snowflake, you need to create the following six environment variables in Gitpod. This template uses Snowflake's key pair authentication method. By changing the environment variables and adapting the profiles.yml, it is possible to connect to Snowflake using the other methods that are listed in the dbt documentation. Since this config includes your private key, we encourage you to only use it for testing. Please check this blog post on how to manage your SSH keys with 1password.

  • DBT_SNOWFLAKE_USER: your username
  • DBT_SNOWFLAKE_PRIVATE_KEY: the content of the private SSH key file (ensure that newlines are represented by whitespaces)
  • DBT_SNOWFLAKE_ACCOUNT: the address of your Snowflake instance
  • DBT_SNOWFLAKE_WH: the name of the warehouse
  • DBT_SNOWFLAKE_DB: the name of the database
  • DBT_SNOWFLAKE_SCHEMA: the name of the schema you want to use for dbt

Please check the dbt configuration if you want to connect to any other data warehouse.

Next Steps

Click the button below to start a new development environment:

Open in Gitpod

The workspace will then try to connect to your data warehose. To use the models in this example project you need to run the following commands.

  1. dbt seed: to materialize the CSVs
  2. dbt run: to run the models
  3. dbt test: to test all models

Get Started With Your Own Project

A new project

Click the above "Open in Gitpod" button to start a new workspace. Once you're ready to push your first code changes, Gitpod will guide you to fork this project so you own it.

An existing project

To get started with dbt on Gitpod, add a .gitpod.yml to any of your existing dbt projects. To learn more, please see the Getting Started documentation.

Optional

Open in VS Code Open in Glitch Open in GitHub Codespaces Edit in Codesandbox Open in StackBlitz Open in Repl.it Open in Codeanywhere

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published