Skip to content

Commit

Permalink
ci: disable seccomp when running podman with GitHub Actions
Browse files Browse the repository at this point in the history
Fedora 40 builds seems to require disabling seccomp. When enabled,
installing Golang inside the container fails.

See-also: containers/podman#21012
Signed-off-by: Niels de Vos <[email protected]>
  • Loading branch information
nixpanic committed Jul 31, 2024
1 parent be84fc5 commit 50c9af0
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,11 @@ ifeq ($(HAVE_CPUSET),1)
CPUSET ?= --cpuset-cpus=0-${CPUS}
endif

ifneq ($(GITHUB_ACTION),)
# see https://github.com/containers/podman/issues/21012
SECURITY_OPT ?= --security-opt seccomp=unconfined
endif

CSI_IMAGE_NAME=$(if $(ENV_CSI_IMAGE_NAME),$(ENV_CSI_IMAGE_NAME),quay.io/cephcsi/cephcsi)
CSI_IMAGE_VERSION=$(shell . $(CURDIR)/build.env ; echo $${CSI_IMAGE_VERSION})
CSI_IMAGE=$(CSI_IMAGE_NAME):$(CSI_IMAGE_VERSION)
Expand Down Expand Up @@ -229,7 +234,7 @@ ifeq ($(USE_PULLED_IMAGE),no)
.test-container-id: .container-cmd build.env scripts/Dockerfile.test
[ ! -f .test-container-id ] || $(CONTAINER_CMD) rmi $(CSI_IMAGE_NAME):test
$(RM) .test-container-id
$(CONTAINER_CMD) build $(CPUSET) --build-arg GOARCH=$(GOARCH) -t $(CSI_IMAGE_NAME):test -f ./scripts/Dockerfile.test .
$(CONTAINER_CMD) build $(CPUSET) $(SECURITY_OPT) --build-arg GOARCH=$(GOARCH) -t $(CSI_IMAGE_NAME):test -f ./scripts/Dockerfile.test .
$(CONTAINER_CMD) inspect -f '{{.Id}}' $(CSI_IMAGE_NAME):test > .test-container-id
else
# create the .test-container-id file based on the pulled image
Expand Down

0 comments on commit 50c9af0

Please sign in to comment.