Skip to content

Commit

Permalink
fix(kubernetes_platform): fix api-generator docker mount for SELinux (#…
Browse files Browse the repository at this point in the history
…10890)

On Fedora, which runs SELinux, mounting the container to the local
filesystem results in permission issues because the labels mismatch:
`make: stat: Makefile: Permission denied`

To fix this, change the directory mount to use the `-v` syntax and
add the `:z` option at the end. Ref:
https://docs.docker.com/storage/bind-mounts/#configure-the-selinux-label

Signed-off-by: Greg Sheremeta <[email protected]>
  • Loading branch information
gregsheremeta authored Jun 13, 2024
1 parent b57f9e8 commit e69078b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion kubernetes_platform/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ clean: clean-go clean-python
golang: proto/*.proto
docker run --interactive --rm \
--user $$(id -u):$$(id -g) \
--mount type=bind,source="$$(pwd)/..",target=/go/src/github.com/kubeflow/pipelines \
-v "$$(pwd)/..":"/go/src/github.com/kubeflow/pipelines":z \
$(PREBUILT_REMOTE_IMAGE) \
sh -c 'cd /go/src/github.com/kubeflow/pipelines/kubernetes_platform && make generate-go-in-container'

Expand Down

0 comments on commit e69078b

Please sign in to comment.