-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
🚨 Snowflake produces permanent tables 🚨 #9063
Changes from 35 commits
c6ae621
b88225e
cc499c2
a2517a3
4a51799
a57495c
c56ef54
f8ccfd6
f24ea4b
a6e4c31
4f9f8ae
621ae20
d0ca72a
3aef7c9
05b0b0f
5a9bacd
f7c2d9b
8c96d2d
a0e7399
c0a755b
4f92a66
be09211
93c0b15
0bb000c
7e73552
2f7dc29
b31f5ec
405d038
0c55399
b8db991
d8abb0c
baf0db2
fe10d82
01bcb67
ab662e3
03e38dc
dffe792
663b498
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
# This file is necessary to install dbt-utils with dbt deps | ||
# the content will be overwritten by the transform function | ||
|
||
# Name your package! Package names should contain only lowercase characters | ||
# and underscores. A good package name should reflect your organization's | ||
# name or the intended use of these models | ||
name: "airbyte_utils" | ||
version: "1.0" | ||
config-version: 2 | ||
|
||
# This setting configures which "profile" dbt uses for this project. Profiles contain | ||
# database connection information, and should be configured in the ~/.dbt/profiles.yml file | ||
profile: "normalize" | ||
|
||
# These configurations specify where dbt should look for different types of files. | ||
# The `source-paths` config, for example, states that source models can be found | ||
# in the "models/" directory. You probably won't need to change these! | ||
source-paths: ["models"] | ||
docs-paths: ["docs"] | ||
analysis-paths: ["analysis"] | ||
test-paths: ["tests"] | ||
data-paths: ["data"] | ||
macro-paths: ["macros"] | ||
|
||
target-path: "../build" # directory which will store compiled SQL files | ||
log-path: "../logs" # directory which will store DBT logs | ||
modules-path: "/tmp/dbt_modules" # directory which will store external DBT dependencies | ||
|
||
clean-targets: # directories to be removed by `dbt clean` | ||
- "build" | ||
- "dbt_modules" | ||
|
||
quoting: | ||
database: true | ||
# Temporarily disabling the behavior of the ExtendedNameTransformer on table/schema names, see (issue #1785) | ||
# all schemas should be unquoted | ||
schema: false | ||
identifier: true | ||
|
||
# You can define configurations for models in the `source-paths` directory here. | ||
# Using these configurations, you can enable or disable models, change how they | ||
# are materialized, and more! | ||
models: | ||
+transient: false | ||
airbyte_utils: | ||
+materialized: table | ||
generated: | ||
airbyte_ctes: | ||
+tags: airbyte_internal_cte | ||
+materialized: ephemeral | ||
airbyte_incremental: | ||
+tags: incremental_tables | ||
+materialized: incremental | ||
+on_schema_change: sync_all_columns | ||
airbyte_tables: | ||
+tags: normalized_tables | ||
+materialized: table | ||
airbyte_views: | ||
+tags: airbyte_internal_views | ||
+materialized: view | ||
|
||
dispatch: | ||
- macro_namespace: dbt_utils | ||
search_order: ["airbyte_utils", "dbt_utils"] |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
FROM fishtownanalytics/dbt:0.21.1 | ||
COPY --from=airbyte/base-airbyte-protocol-python:0.1.1 /airbyte /airbyte | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. do we need to get this docker image anymore? can't we just There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. is the COPY command equivalent to that pip install? (looks like the the docker image just contains |
||
|
||
# Install SSH Tunneling dependencies | ||
RUN apt-get update && apt-get install -y jq sshpass | ||
|
||
WORKDIR /airbyte | ||
COPY entrypoint.sh . | ||
COPY build/sshtunneling.sh . | ||
|
||
WORKDIR /airbyte/normalization_code | ||
COPY normalization ./normalization | ||
COPY setup.py . | ||
COPY dbt-project-template/ ./dbt-template/ | ||
COPY dbt-project-template-snowflake/* ./dbt-template/ | ||
|
||
# Install python dependencies | ||
WORKDIR /airbyte/base_python_structs | ||
RUN pip install . | ||
|
||
WORKDIR /airbyte/normalization_code | ||
RUN pip install . | ||
|
||
WORKDIR /airbyte/normalization_code/dbt-template/ | ||
# Download external dbt dependencies | ||
RUN dbt deps | ||
|
||
WORKDIR /airbyte | ||
ENV AIRBYTE_ENTRYPOINT "/airbyte/entrypoint.sh" | ||
ENTRYPOINT ["/airbyte/entrypoint.sh"] | ||
|
||
LABEL io.airbyte.version=0.1.62 | ||
LABEL io.airbyte.name=airbyte/normalization-snowflake |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
are we creating a special dockerfile for snowflake because it's DBT yamls deviate from the standard yamls?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah. Chris suggested modifying
entrypoint.sh
to use the modified yaml instead of publishing a new docker image, but my thinking was to keep entrypoint.sh integration-agnostic.