Skip to content
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

Correct bind mount for profiles.yml in documentation #6641

Merged
merged 4 commits into from
Dec 17, 2024

Conversation

Sparrow0hawk
Copy link
Contributor

What are you changing in this pull request and why?

Corrects the bind mount for profiles.yml which previously mounted the host profiles.yml file to /root/.dbt in the Docker install instructions.

Checklist

  • I have reviewed the Content style guide so my content adheres to these guidelines.
  • The topic I'm writing about is for specific dbt version(s) and I have versioned it according to the version a whole page and/or version a block of content guidelines.
  • I have added checklist item(s) to this list for anything anything that needs to happen before this PR is merged, such as "needs technical review" or "change base branch."
  • The content in this PR requires a dbt release note, so I added one to the release notes page.

Corrects the bind mount for profiles.yml which previously mounted the host profiles.yml file to /root/.dbt.
@Sparrow0hawk Sparrow0hawk requested a review from a team as a code owner December 11, 2024 15:45
Copy link

welcome bot commented Dec 11, 2024

Hello!👋 Thanks for contributing to the dbt product documentation and opening this pull request! ✨
We use Markdown and some HTML to write the dbt product documentation. When writing content, you can use our style guide and content types to understand our writing standards and how we organize information in the dbt product docs.
We'll review your contribution and respond as soon as we can. 😄

Copy link

vercel bot commented Dec 11, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
docs-getdbt-com ✅ Ready (Inspect) Visit Preview Dec 11, 2024 3:48pm

Copy link

vercel bot commented Dec 11, 2024

@Sparrow0hawk is attempting to deploy a commit to the dbt-labs Team on Vercel.

A member of the Team first needs to authorize it.

@github-actions github-actions bot added the content Improvements or additions to content label Dec 11, 2024
@runleonarun runleonarun added the new contributor Label for first-time contributors label Dec 11, 2024
@github-actions github-actions bot added the size: x-small This change will take under 3 hours to fix. label Dec 11, 2024
@Sparrow0hawk Sparrow0hawk changed the title Correct bind mount for profiles.yml Correct bind mount for profiles.yml in documentation Dec 11, 2024
@github-actions github-actions bot added size: small This change will take 1 to 2 days to address and removed size: x-small This change will take under 3 hours to fix. labels Dec 17, 2024
Copy link
Contributor

@mirnawong1 mirnawong1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hey @Sparrow0hawk , thanks for opening this up and great addition! i've consulted with my teammate @jeremyyeo and it looks like both options work so i've added that there. thanks again!

@mirnawong1 mirnawong1 merged commit d61fc8f into dbt-labs:current Dec 17, 2024
2 of 3 checks passed
@Sparrow0hawk
Copy link
Contributor Author

Hi @mirnawong1 and @jeremyyeo thanks for this. Just to confirm I cannot get the previous documented way to work.

I'm running Docker version 27.3.1, build ce12230, if I run the following command within my DBT project directory it does not find my profiles.yml.

docker run \
  --network=host \
  --mount type=bind,source=${PWD},target=/usr/app \
  --mount type=bind,source=${PWD}/profiles.yml,target=/root/.dbt/ \
  ghcr.io/dbt-labs/dbt-bigquery:1.9.latest \
  run

11:53:26  Running with dbt=1.9.0
11:53:26  Encountered an error:
Runtime Error
  Could not find profile named 'transformations'

If I get the container to run ls on /root/.dbt/ it gives an error saying the directory does not exist:

docker run \
--entrypoint "ls" \
--rm -it \
--mount type=bind,source=${PWD},target=/usr/app \
--mount type=bind,source=${PWD}/profiles.yml,target=/root/.dbt/ \
ghcr.io/dbt-labs/dbt-bigquery:1.9.latest \
/root/.dbt/
ls: cannot access '/root/.dbt/': Not a directory

If I shell into the container and cat /root/.dbt I can see that contains the contents of my profiles.yml file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
content Improvements or additions to content new contributor Label for first-time contributors size: small This change will take 1 to 2 days to address
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants