Created
February 5, 2020 16:08
-
-
Save kholisrag/2c761f5804030177c3bcc0ee6f7f8501 to your computer and use it in GitHub Desktop.
Bash Script / Shell Script Function to Disable Auto Update and Auto Upgrade in Ubuntu
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
function patch_apt() { | |
echo "Patching System Auto Update and Auto Upgrade..." | |
sed -i 's/1/0/g' /etc/apt/apt.conf.d/10periodic | |
sed -i 's/1/0/g' /etc/apt/apt.conf.d/20auto-upgrades | |
apt-get clean | |
echo "Auto Update and Auto Upgrade Disabled!!!" | |
} | |
patch_apt |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment