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

Bug Report: Permission error when using db example #96

Open
hphu3 opened this issue Jun 30, 2023 · 6 comments
Open

Bug Report: Permission error when using db example #96

hphu3 opened this issue Jun 30, 2023 · 6 comments
Labels
bug Something isn't working

Comments

@hphu3
Copy link

hphu3 commented Jun 30, 2023

Describe the bug
We've configured the database according to the postgres testing example in the docs: https://circleci.com/docs/databases/#postgresql-database-testing-example

when running the image step, there is a
could not change directory to "/home/circleci/project": Permission denied
and
Build was canceled

To Reproduce
Clone the example config from the docs and create a new repo.

Expected behavior
Expected the image to load without any errors

Workarounds
The tests still seem to run, can this message be safely ignored?

Screenshots and Build Links
Screen Shot 2023-06-30 at 2 35 03 PM

Here's our test repo: https://github.com/inventables/psql-test and the build: https://app.circleci.com/pipelines/github/inventables/psql-test/1/workflows/cba69c18-14c4-4627-a095-17007117e2b2/jobs/1

Additional context
Add any other context about the problem here.
The image has a WORKDIR /home/circleci/project command. I'm not sure what the reasoning is for it or if it's needed.
https://hub.docker.com/layers/cimg/postgres/13.11/images/sha256-dd0031cb27d079e6bcfdbc3c73363246ace95ddad007257887d91c2cefe11a4d?context=explore

@hphu3 hphu3 added the bug Something isn't working label Jun 30, 2023
@mlabarca
Copy link

I'm having the same error, same 13.11 image, tests also passing.

@TannerW
Copy link

TannerW commented Jul 26, 2023

Any news on this? Ran into this problem myself

@BytesGuy
Copy link
Contributor

BytesGuy commented Sep 4, 2023

Hi @hphu3 @mlabarca @TannerW is this actually causing build failures in your jobs?

From what I am seeing, the Build was cancelled is the standard error message for when secondary containers are torn down after the main containers work is complete. The error message is definitely not very easy to understand, but this is not an image specific issue - you would see the same for any image used in a secondary container as it is handled by the CircleCI platform itself.

The directory issue can also be safely ignored as there is no code checkout into the second container, it is simply exposing a service on the port. Unless this is actually causing build failures, it is not something we need to investigate.

@BytesGuy BytesGuy self-assigned this Sep 4, 2023
@aviemet
Copy link

aviemet commented Sep 9, 2023

I'm glad I finally found this discussion so I know to ignore the permissions issue. My setup is failing and in trying to troubleshoot I've lost a good chunk of time trying to look into this. While it can safely be ignored, perhaps it can be addressed so that it isn't extra noise which sends people down the wrong path while troubleshooting. If not addressed, perhaps noted in the docs? Thank you

@eternaltyro
Copy link

I think the issue still warrants better log messages since it is hard to ignore this ominous message when the builds are failing. That the secondary image is being torn down because the primary image has completed it's job (or exited prematurely) should be made clear somewhere.

@jaredbeck
Copy link

In addition to the issues in the above comments, I found the following to be confusing:

  • It says "Build was canceled" even when all jobs pass
  • The icon is a grey hyphen instead of a green checkmark

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

7 participants