From c86bf5cae3dc05c3b607e02532b1137ce17803d3 Mon Sep 17 00:00:00 2001 From: Silvio Rhatto Date: Sun, 20 Mar 2016 14:57:28 -0300 Subject: Jessie customizations and script reordering --- share/hydractl/system-upgrade | 28 +++++++++++++++++++++------- 1 file changed, 21 insertions(+), 7 deletions(-) (limited to 'share/hydractl') diff --git a/share/hydractl/system-upgrade b/share/hydractl/system-upgrade index b9a6b96..f0c42b1 100755 --- a/share/hydractl/system-upgrade +++ b/share/hydractl/system-upgrade @@ -130,13 +130,6 @@ function hydra_system_upgrade_upgrade { exit 1 fi - hydra_system_upgrade_stage cleanup -} - -# Cleanup procedures -function hydra_system_upgrade_cleanup { - apt-get autoremove -y - apt-get clean hydra_system_upgrade_stage custom } @@ -153,7 +146,28 @@ function hydra_system_upgrade_custom { fi fi + if [ "$nextrelease" == "jessie" ]; then + # We're using a masterless puppet setup, so no agent + apt-get install puppet-common + apt-get purge puppet + + # Purge old monitoring infrastructure + apt-get purge 'munin*' 'nagios*' + rm -rf /etc/nagios* /etc/munin* /etc/munin* /usr/share/munin* + + # Cleanup old scripts + rm -f /usr/local/sbin/check-puppetd.sh + rm -f remove /etc/cron.d/puppetd + fi + hydractl trac-upgrade + hydra_system_upgrade_stage cleanup +} + +# Cleanup procedures +function hydra_system_upgrade_cleanup { + apt-get autoremove --purge -y + apt-get clean } # Initialize -- cgit v1.2.3