From 1e28428574fdbecd0ec0375ba3490ce355f6dd07 Mon Sep 17 00:00:00 2001 From: Alexandre Pujol Date: Sun, 6 Oct 2024 16:19:11 +0100 Subject: [PATCH] ci: run on ubuntu 24.04 & enable make check. --- .github/workflows/main.yml | 12 +++++++----- .gitlab-ci.yml | 5 +++++ apparmor.d/profiles-s-z/xarchiver | 2 +- 3 files changed, 13 insertions(+), 6 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 8a57149d..b3fc6b99 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -8,17 +8,16 @@ jobs: strategy: matrix: os: - # - ubuntu-24.04 + - ubuntu-24.04 - ubuntu-22.04 mode: - default - full-system-policy steps: - - name: Check out repository code uses: actions/checkout@v4 - - name: Install Build dependencies + - name: Install Build dependencies run: | sudo apt-get update -q sudo apt-get install -y \ @@ -39,12 +38,15 @@ jobs: run: sudo dpkg --install ../apparmor.d_*_amd64.deb || true - name: Reload AppArmor - run: | + run: | sudo systemctl restart apparmor.service || true sudo systemctl status apparmor.service - name: Ensure compatibility with some AppArmor userspace tools - run: sudo aa-enforce /etc/apparmor.d/aa-notify + run: + if [[ ${{ matrix.os }} != ubuntu-24.04 ]]; then + sudo aa-enforce /etc/apparmor.d/aa-notify + fi - name: Show AppArmor log and rules run: | diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 40f21276..2aed9b55 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -63,6 +63,11 @@ tests: - go test $(go list ./pkg/... | grep -v /pkg/paths) -v -cover -coverprofile=coverage.out - go tool cover -func=coverage.out +check: + stage: lint + image: registry.gitlab.com/roddhjav/builders/archlinux + script: + - make check # Package Build # ------------- diff --git a/apparmor.d/profiles-s-z/xarchiver b/apparmor.d/profiles-s-z/xarchiver index 9f87e3b9..00377000 100644 --- a/apparmor.d/profiles-s-z/xarchiver +++ b/apparmor.d/profiles-s-z/xarchiver @@ -42,7 +42,7 @@ profile xarchiver @{exec_path} { # For deb packages @{bin}/{,@{multiarch}-}ar rix, - @{path_open} rPx -> child-open, + @{open_path} rPx -> child-open, /etc/fstab r,