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
# wget https://gist.github.com/ydf/8c5a7f80ee84dd24c5c676f84929b1f8/raw/dda2ab31a16fc5ab436666d2162bd2db85350632/deploy_unattended-upgrades.sh -O /tmp/a && sh /tmp/a | |
apt-get -y install unattended-upgrades && \ | |
cat > /etc/apt/apt.conf.d/10periodic <<EOF | |
APT::Periodic::Update-Package-Lists "1"; | |
APT::Periodic::Download-Upgradeable-Packages "1"; | |
APT::Periodic::AutocleanInterval "3"; | |
APT::Periodic::Unattended-Upgrade "1"; | |
EOF | |
sed -i 's#//\t"${distro_id}:${distro_codename}-updates"#\t"${distro_id}:${distro_codename}-updates"#' /etc/apt/apt.conf.d/50unattended-upgrades && \ |
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 | |
# This is my production backup script. | |
# https://sqlgossip.com | |
set -e | |
set -u | |
usage() { | |
echo "usage: $(basename $0) [option]" | |
echo "option=full: Perform Full Backup" |