mirror of
https://github.com/actions/runner-images.git
synced 2025-12-20 06:35:47 +00:00
Bug: Mask fwupd timer on ubuntu images (#12225)
* Bug: Fully remove `fwupd` from ubuntu images We're running on VMs in Azure and the fwupd package is not needed. Leaving it enable means periodic refreshes show in network traffic and firewall logs. * Update check method * Simplify test
This commit is contained in:
@@ -59,9 +59,18 @@ ln -s $HELPER_SCRIPTS/invoke-tests.sh /usr/local/bin/invoke_tests
|
||||
# Disable motd updates metadata
|
||||
sed -i 's/ENABLED=1/ENABLED=0/g' /etc/default/motd-news
|
||||
|
||||
# Remove fwupd if installed. We're running on VMs in Azure and the fwupd package is not needed.
|
||||
# Leaving it enable means periodic refreshes show in network traffic and firewall logs
|
||||
# Check if fwupd-refresh.timer exists in systemd
|
||||
if systemctl list-unit-files fwupd-refresh.timer &>/dev/null; then
|
||||
echo "Masking fwupd-refresh.timer..."
|
||||
systemctl mask fwupd-refresh.timer
|
||||
fi
|
||||
|
||||
# This is a legacy check, leaving for earlier versions of Ubuntu
|
||||
# If fwupd config still exists, disable the motd updates
|
||||
if [[ -f "/etc/fwupd/daemon.conf" ]]; then
|
||||
sed -i 's/UpdateMotd=true/UpdateMotd=false/g' /etc/fwupd/daemon.conf
|
||||
systemctl mask fwupd-refresh.timer
|
||||
fi
|
||||
|
||||
# Disable to load providers
|
||||
|
||||
Reference in New Issue
Block a user