mirror of
https://github.com/morgan9e/systemd
synced 2026-04-14 00:14:32 +09:00
mkosi: Run more commands as root
zypper has some new rather questionable userspace level permission checking that blows ups completely when operating as root on an cache directory owned by a non-root user, so let's build the tools tree and set up meson as root to avoid the issue. (https://github.com/openSUSE/libzypp/issues/603) Also drop a leftover debug message from coverage.yml while we're at it.
This commit is contained in:
20
.github/workflows/coverage.yml
vendored
20
.github/workflows/coverage.yml
vendored
@@ -83,21 +83,25 @@ jobs:
|
||||
run: mkosi summary
|
||||
|
||||
- name: Build tools tree
|
||||
run: mkosi -f sandbox true
|
||||
|
||||
- name: PATH
|
||||
run: echo "$PATH"
|
||||
run: sudo --preserve-env mkosi -f sandbox true
|
||||
|
||||
- name: Configure meson
|
||||
run: mkosi sandbox meson setup --buildtype=debugoptimized -Dintegration-tests=true build
|
||||
run: |
|
||||
sudo --preserve-env --preserve-env=PATH \
|
||||
mkosi sandbox \
|
||||
meson setup \
|
||||
--buildtype=debugoptimized \
|
||||
-Dintegration-tests=true \
|
||||
build
|
||||
|
||||
- name: Build image
|
||||
run: sudo --preserve-env mkosi sandbox meson compile -C build mkosi
|
||||
|
||||
- name: Initial coverage report
|
||||
run: |
|
||||
mkdir -p build/test/coverage
|
||||
mkosi sandbox \
|
||||
sudo --preserve-env mkdir -p build/test/coverage
|
||||
sudo --preserve-env \
|
||||
mkosi sandbox \
|
||||
lcov \
|
||||
--directory build/mkosi.builddir/arch~rolling~x86-64 \
|
||||
--capture \
|
||||
@@ -141,7 +145,7 @@ jobs:
|
||||
lcov_args+=(--add-tracefile "${file}")
|
||||
done < <(find build/test/coverage -name "TEST-*.coverage-info")
|
||||
|
||||
mkosi sandbox lcov --ignore-errors inconsistent,inconsistent "${lcov_args[@]}" --output-file build/test/coverage/everything.coverage-info
|
||||
sudo --preserve-env mkosi sandbox lcov --ignore-errors inconsistent,inconsistent "${lcov_args[@]}" --output-file build/test/coverage/everything.coverage-info
|
||||
|
||||
- name: List coverage report
|
||||
run: mkosi sandbox lcov --ignore-errors inconsistent,inconsistent --list build/test/coverage/everything.coverage-info
|
||||
|
||||
Reference in New Issue
Block a user