Open lahwaacz opened 1 year ago
@lahwaacz,
Could you try the solution mentioned here? https://github.com/containers/buildah/issues/1702#issuecomment-508143700
@nikkon-dev Thanks for the advice. I did not try passing --no-same-owner
to tar
, but extending the UID/GID mapping to provide 262144 IDs (4 * 2^16) for docker containers allowed the build to pass.
But now I have a problem when I try to use the image to actually build DCGM. The build script gives this error:
+ ./build.sh --arch amd64 --sa-mode 0 --release --
fatal: --local can only be used inside a git repository
Installing git-lfs locally
Error: failed to call git rev-parse --git-dir: exit status 128 : fatal: detected dubious ownership in repository at '/workspaces/DCGM'
To add an exception for this directory, call:
git config --global --add safe.directory /workspaces/DCGM
Not in a git repository.
I see the script runs a docker container with -u "$(id -u)":"$(id -g)"
and maps the cloned git repository as a volume to /workspaces/DCGM
in the container, which does not work correctly with user namespacing...
I have Docker configured with unprivileged user namespace isolation using 65536 UIDs and GIDs starting from 864165. I tried to build the image according to the readme, but it failed with these errors: