https://garden.io logo
#🌱|help-and-getting-started
fatal: detected dubious ownership in repository at /user/local/bin/static
# 🌱|help-and-getting-started
w

wide-flag-41451

01/17/2024, 6:18 PM
Hi I have a github actions CI work flow that runs garden deploy the garden version is 0.13.14 and i receive the following error:
Copy code
Deploy
Unexpected Git error occurred while running 'git status' from path "/usr/local/bin/static". Exit code: 128. Error message: fatal: detected dubious ownership in repository at '/usr/local/bin/static'
the garden command is running inside a custom image i have built specifically for CI. Additionally i have this same image being used in gitea as well which does not throw an error. I suspect it has something to do with it running in a github environment(potentially need to chmod something in the dev container) but due to the fact that its still running within a custom built image I find that somewhat hard to believe. The error suggests that
git config --global --add safe.directory /usr/local/bin/static
fixes the issue however that just produces an error saying that the working directory is not a git repository. I'm not entirely sure this is a garden issue but i would need some help to determine if its my setup or garden. Thanks
q

quaint-dress-831

01/18/2024, 8:17 AM
Hi @wide-flag-41451 this is just the nature of Git: especially in containers, mixed ownership of files is common and Git dislikes this. I thought we had gotten rid of the Git directory Garden installs in more recent versions. I'd first try and pull in the latest binary but you can also do as I did and simply curl in Garden to your image declared in your Dockerfile. See https://gitlab.hansen.agency/worldofgeese/little_bits_of_buddha/-/blob/main/prebuild-devcontainer/Dockerfile?ref_type=heads#L49
w

wide-flag-41451

01/18/2024, 2:18 PM
ty , i got aorund the issue by chown the git directory to root
q

quaint-dress-831

01/18/2024, 2:49 PM
Great! Just FYI we did in fact get rid of the static directory back in 0.13.20 https://github.com/garden-io/garden/releases/tag/0.13.20
So no workarounds should be necessary if you use the latest garden
2 Views