diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 1c448f7..5203f92 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -29,7 +29,7 @@ jobs: session requisite pam_permit.so session required pam_permit.so" | tee /etc/pam.d/sr' - name: Install RootAsRole - run: cargo xtask install -bia + run: sudo cargo xtask install -bia - name: Add read access on config on rootasrole... Because Github Actions... run: sudo chmod a+r /etc/security/rootasrole.json - name: print config diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 5369d10..cf68a73 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -25,9 +25,6 @@ jobs: - name: Install sudo run: apt install sudo -y - - name: Install RootAsRole - run: cargo xtask install -bia - - name: run tests with coverage run: cargo +nightly tarpaulin --verbose --all-features --workspace --timeout 120 --bin chsr --bin sr --exclude-files build.rs xtask* --out Xml diff --git a/xtask/src/install/install.rs b/xtask/src/install/install.rs index 68ccf7c..dff9071 100644 --- a/xtask/src/install/install.rs +++ b/xtask/src/install/install.rs @@ -86,7 +86,7 @@ pub fn install(profile: Profile, clean_after: bool, copy: bool) -> Result<(), an || !state.permitted.has(Cap::SETFCAP) { return Err(anyhow!( - "You need CAP_DAC_OVERRIDE, CAP_CHOWN and CAP_CHOWN capabilities to install rootasrole. + "You need CAP_DAC_OVERRIDE, CAP_CHOWN and CAP_SETFCAP capabilities to install rootasrole. \nConsider using `sr cargo xtask install` or use sudo if sr is currently not installed." )); }