Skip to content

Commit 5b57149

Browse files
Merge pull request #9 from Snowflake-Labs/coco_workflows
Updates to Cortex Agent and Cortex Search deployments as managed through dbt macro ops.
2 parents da587ae + 2fb1601 commit 5b57149

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+1845
-953
lines changed

.env.template

Lines changed: 37 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,66 +1,70 @@
1-
# DBT Environment Variables for Incident Management Project
1+
# Incident Management Project - Environment Variables
22
#
33
# Copy this file to .env and update with your actual values
44
# Make sure to keep .env file secure and never commit it to version control
55

66

77
# =============================================================================
8-
# SNOWFLAKE CLI CONFIGURATION
9-
# =============================================================================
10-
11-
export SNOWFLAKE_CLI_FEATURES_ENABLE_DBT=true
12-
13-
# =============================================================================
14-
# GIT INTEGRATION ENVIRONMENT VARIABLES
8+
# REQUIRED: You MUST set these values for your environment
159
# =============================================================================
1610

11+
export SNOWFLAKE_USER=<snowflake user with Snowsight access; same as connection name in config.toml>
1712
export GIT_REPOSITORY_URL=<git-repo-where-dbt-project-will-be-checked-in>
18-
export REPO_DBT_PROJECTS_YML_PATH=src/incident_management
19-
export SNOWFLAKE_GIT_API_INT=incm_git_intgeration
2013
export GIT_USER_EMAIL=<your-git-email>
2114
export GIT_USER_REPO_PAT=<your-github-personal-access-token>
15+
export DBT_DEPS_EAI=<external-access-integration-object>
16+
export SNOWFLAKE_INTELLIGENCE_INT_OBJECT=<snowflake-intelligence-integration-object>
2217

2318
# =============================================================================
24-
# DBT PROJECT DEPLOYMENT ENVIRONMENT VARIABLES
19+
# PRE-CONFIGURED DEFAULTS: Change only if customizing the deployment
2520
# =============================================================================
2621

27-
## pre-configured; do not change!
22+
export SNOWFLAKE_CLI_FEATURES_ENABLE_DBT=true
23+
24+
## Project identifiers
2825
export DBT_PROJECT_DATABASE=v1_incident_management
29-
export DBT_PROJECT_SCHEMA=dbt_project_deployments
3026
export MODEL_SCHEMA=bronze_zone
3127
export DBT_PROJECT_ADMIN_ROLE=v1_dbt_projects_engineer
3228
export DBT_PROJECT_NAME=dbt_incident_management
3329

34-
## modify based on your execution context and Snowflake account
35-
export SNOWFLAKE_USER=<snowflake user with Snowsight access; this is assumed the same as connection name in Connections.toml>
36-
export DBT_SNOWFLAKE_ACCOUNT=<snowflake-account-locator>
37-
export DBT_SNOWFLAKE_PASSWORD=<snowflake-programmatic-access-token>
38-
export DBT_DEPS_EAI=<external-access-integration-object>
39-
export DAILY_REFRESH_CRON_SCHEDULE='USING CRON 1 0 * * * America/Toronto'
40-
export WEEKLY_REFRESH_CRON_SCHEDULE='USING CRON 0 1 * * 1 America/New_York'
30+
## Git integration
31+
export REPO_DBT_PROJECTS_YML_PATH=src/incident_management
32+
export SNOWFLAKE_GIT_API_INT=incm_git_intgeration
33+
export GIT_BRANCH=main
34+
35+
## dbt execution
4136
export DBT_TARGET=dev
4237
export DBT_THREADS=1
43-
44-
## For use when deploying from local dbt project directory
4538
export DBT_PROJECT_DIR=src/incident_management
4639

40+
## Schedules
41+
export DAILY_REFRESH_CRON_SCHEDULE='USING CRON 1 0 * * * America/Toronto'
42+
export WEEKLY_REFRESH_CRON_SCHEDULE='USING CRON 0 1 * * 1 America/New_York'
43+
44+
## Warehouses
45+
export DBT_PIPELINE_WH=v1_demo_wh
46+
export CORTEX_SEARCH_WH=document_search_service_wh
47+
48+
## Cortex Services
49+
export CORTEX_SEARCH_WH=<name of the warehouse for the cortex search service>
50+
export CORTEX_SEARCH_SERVICE_NAME=<name of the cortex search service>
4751

4852
# =============================================================================
49-
# SLACK CONNECTOR ENVIRONMENT VARIABLES
53+
# OPTIONAL: Slack Connector (only needed for 'make setup-slack-connector')
5054
# =============================================================================
55+
5156
export OPENFLOW_USER=<name of the user who owns the Openflow runtime>
52-
export SLACK_CONNECTOR_ROLE=v1_slack_connector_role
5357
export OPENFLOW_RUNTIME_USAGE_ROLE=<role created with access to Openflow SPCS runtime for USAGE>
58+
export SLACK_CONNECTOR_ROLE=v1_slack_connector_role
59+
export SLACK_CONNECTOR_WH=v1_demo_wh
5460

55-
# =============================================================================
56-
# STREAMLIT APP DEPLOYMENT
57-
# =============================================================================
58-
STREAMLIT_DEPLOYMENT_ENABLED=true
5961

6062
# =============================================================================
61-
# WAREHOUSES
63+
# OPTIONAL: Streamlit App (only needed for 'make deploy-streamlit')
6264
# =============================================================================
63-
export DBT_PIPELINE_WH=v1_demo_wh
64-
export CORTEX_SEARCH_WH=document_search_service_wh
65-
export SLACK_CONNECTOR_WH=v1_demo_wh
66-
export STREAMLIT_QUERY_WH=v1_demo_wh
65+
66+
STREAMLIT_DEPLOYMENT_ENABLED=true
67+
export STREAMLIT_QUERY_WH=v1_demo_wh
68+
export DBT_PROJECT_SCHEMA=dbt_project_deployments
69+
export DBT_SNOWFLAKE_ACCOUNT=<snowflake-account-locator>
70+
export DBT_SNOWFLAKE_PASSWORD=<snowflake-programmatic-access-token>

0 commit comments

Comments
 (0)