Jason Maddern
01/10/2023, 5:29 AMrun --selector partner_staging
That then goes and:
• Pulls down my github repo and docker image
• Builds the image and dynamically creates the profiles.yml file
The issue I'm facing is that when Airbyte auto builds the profiles.yml from the airbyte destination config it seems to auto create output of prod and I have no way of overriding it - it looks like this:
config:
partial_parse: true
printer_width: 120
send_anonymous_usage_stats: false
use_colors: true
normalize:
outputs:
prod:
account: {obfuscated}
client_session_keep_alive: false
connect_retries: 3
connect_timeout: 15
database: DEV_PP_AIRBYTE_DB
password: {obfuscated}
query_tag: normalization
retry_all: true
retry_on_database_errors: true
role: DEV_LOADER
schema: PP
threads: 5
type: snowflake
user: {obfuscated}
warehouse: DEV_LOADING
target: prod
This is problematic when defaulting to prod because I have a heap of jinja in dbt to handle prod/nonprod environments like this:
+database: |
{%- if "dev" in target.name -%} DEV_STUDYLINK_ANALYTICS
{%- elif "prod" in target.name -%} STUDYLINK_ANALYTICS
{%- else -%} invalid_staging_admit_database
{%- endif -%}
This isn't an issue if I run DBT myself, because I can have my own profiles output called dev or prod and inject the --target on run. This allows the same code to run across prod/nonprod. But it's a problem for Airbyte as it seems to auto-create the fixed values of normalise and prod as the target.
How can we configure airbyte so that when it does DBT transformations it doesn't auto create the profiles with target prod?
FYI @Varun Khannauser
01/25/2023, 8:54 PMJason Maddern
02/10/2023, 6:54 AM