We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Similarly to #2486, a port number cannot be provided via environment variable.
default: outputs: production: type: postgres threads: 1 host: "{{ env_var('DBT_HOST') }}" port: "{{ env_var('DBT_PORT') }}" user: "{{ env_var('DBT_USER') }}" pass: "{{ env_var('DBT_PASS') }}" dbname: "{{ env_var('DBT_DBNAME') }}" schema: "{{ env_var('DBT_SCHEMA') }}" target: production
Results in:
Credentials in profile "default", target "production" invalid: '5432' is not of type 'integer'
See above config.
Ability to pass port as env var.
See above.
Which database are you using dbt with?
The output of dbt --version:
dbt --version
Using Docker image fishtownanalytics/dbt:0.18.1.
fishtownanalytics/dbt:0.18.1
The operating system you're using:
The output of python --version:
python --version
See #2486
The text was updated successfully, but these errors were encountered:
Hey @moltar, try adding the as_number filter, as shown in the docs:
as_number
default: outputs: production: type: postgres threads: 1 host: "{{ env_var('DBT_HOST') }}" port: "{{ env_var('DBT_PORT') | as_number }}" user: "{{ env_var('DBT_USER') }}" pass: "{{ env_var('DBT_PASS') }}" dbname: "{{ env_var('DBT_DBNAME') }}" schema: "{{ env_var('DBT_SCHEMA') }}" target: production
This was a breaking change in dbt v0.17.1 (#2618 to be precise).
Sorry, something went wrong.
I can confirm that your suggestion does work.
I've tried a variation of that, where I casted it to number, but omitted the quotes, thinking that the quotes would negate the number casting.
Thanks!
This suggestion worked perfectly fine.
No branches or pull requests
Describe the bug
Similarly to #2486, a port number cannot be provided via environment variable.
Results in:
Steps To Reproduce
See above config.
Expected behavior
Ability to pass port as env var.
Screenshots and log output
See above.
System information
Which database are you using dbt with?
The output of
dbt --version
:Using Docker image
fishtownanalytics/dbt:0.18.1
.The operating system you're using:
Using Docker image
fishtownanalytics/dbt:0.18.1
.The output of
python --version
:Using Docker image
fishtownanalytics/dbt:0.18.1
.Additional context
See #2486
The text was updated successfully, but these errors were encountered: