From 5a50175cdcc1648f7c822ccc0fc13a38fd9d4bda Mon Sep 17 00:00:00 2001 From: christophe-duc Date: Wed, 7 Jan 2026 16:01:39 -0400 Subject: [PATCH] Add exclude_graphdriver_btrfs tag to avoid btrfs CGO dependency --- .github/workflows/ci.yml | 6 +++--- .goreleaser.yml | 2 ++ test.sh | 3 ++- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 42347636..95f221e9 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -63,7 +63,7 @@ jobs: podman info - name: Run integration tests run: | - go test -tags=integration,containers_image_openpgp -v ./pkg/commands/... + go test -tags=integration,containers_image_openpgp,exclude_graphdriver_btrfs -v ./pkg/commands/... build: runs-on: ubuntu-latest env: @@ -85,10 +85,10 @@ jobs: ${{runner.os}}-go- - name: Build linux binary run: | - GOOS=linux go build -tags=containers_image_openpgp + GOOS=linux go build -tags=containers_image_openpgp,exclude_graphdriver_btrfs - name: Build darwin binary run: | - GOOS=darwin go build -tags=containers_image_openpgp + GOOS=darwin go build -tags=containers_image_openpgp,exclude_graphdriver_btrfs check-codebase: runs-on: ubuntu-latest env: diff --git a/.goreleaser.yml b/.goreleaser.yml index ed664020..9efeb2fd 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -9,6 +9,7 @@ builds: - id: binary tags: - containers_image_openpgp + - exclude_graphdriver_btrfs goos: - darwin - linux @@ -20,6 +21,7 @@ builds: - id: snap tags: - containers_image_openpgp + - exclude_graphdriver_btrfs goos: - linux goarch: diff --git a/test.sh b/test.sh index a2f71db9..95e8e0d0 100755 --- a/test.sh +++ b/test.sh @@ -6,7 +6,8 @@ echo "" > coverage.txt export GOFLAGS=-mod=vendor # Use pure Go PGP implementation to avoid CGO dependency on gpgme -BUILD_TAGS="-tags=containers_image_openpgp" +# Exclude btrfs driver to avoid CGO dependency on libbtrfs +BUILD_TAGS="-tags=containers_image_openpgp,exclude_graphdriver_btrfs" use_go_test=false if command -v gotest; then