Skip to content

Commit

Permalink
Ignore missing CAP_SYS_NICE in the CI tests as we are not allowed to …
Browse files Browse the repository at this point in the history
…change the nicencess.

Signed-off-by: DL6ER <dl6er@dl6er.de>
  • Loading branch information
DL6ER committed May 28, 2020
1 parent 0c1ab0f commit 5970c05
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion test/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ chown pihole:pihole /etc/pihole /run/pihole /var/log/pihole.log /var/log/pihole-
cp ./pihole-FTL /home/pihole
chmod +x /home/pihole/pihole-FTL
# Note: We cannot add CAP_NET_RAW and CAP_NET_ADMIN at this point
setcap CAP_NET_BIND_SERVICE,CAP_SYS_NICE+eip /home/pihole/pihole-FTL
setcap CAP_NET_BIND_SERVICE+eip /home/pihole/pihole-FTL

# Prepare gravity database
sqlite3 /etc/pihole/gravity.db < test/gravity.db.sql
Expand Down
2 changes: 1 addition & 1 deletion test/test_suite.bats
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,7 @@
}

@test "No WARNING messages in pihole-FTL.log (besides known capability issues)" {
run bash -c 'grep "WARNING:" /var/log/pihole-FTL.log | grep -c -v -E "CAP_NET_ADMIN|CAP_NET_RAW"'
run bash -c 'grep "WARNING:" /var/log/pihole-FTL.log | grep -c -v -E "CAP_NET_ADMIN|CAP_NET_RAW|CAP_SYS_NICE"'
printf "%s\n" "${lines[@]}"
[[ ${lines[0]} == "0" ]]
}
Expand Down

0 comments on commit 5970c05

Please sign in to comment.