mirror of https://github.com/containers/podman.git
Cirrus: Silence systemd-banish noise
It's somewhat hard to predict which units are certinly present for any given base-image. Therefore, at image-build time, it's distracting and unhelpful to see all the errors about units that don't exist, on every platform. Simply ignore them and rely on the `check_image.sh` test to confirm none are enabled. Signed-off-by: Chris Evich <cevich@redhat.com>
This commit is contained in:
parent
e3082762fe
commit
ceb3d76298
|
@ -358,11 +358,14 @@ systemd_banish(){
|
|||
set +e # Not all of these exist on every platform
|
||||
for unit in $EVIL_UNITS
|
||||
do
|
||||
ooe.sh sudo systemctl stop $unit
|
||||
ooe.sh sudo systemctl disable $unit
|
||||
ooe.sh sudo systemctl disable $unit.timer
|
||||
ooe.sh sudo systemctl mask $unit
|
||||
ooe.sh sudo systemctl mask $unit.timer
|
||||
echo "Banishing $unit (ignoring errors)"
|
||||
(
|
||||
sudo systemctl stop $unit
|
||||
sudo systemctl disable $unit
|
||||
sudo systemctl disable $unit.timer
|
||||
sudo systemctl mask $unit
|
||||
sudo systemctl mask $unit.timer
|
||||
) &> /dev/null
|
||||
done
|
||||
set -e
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue