msm/installers/debian.sh

27 lines
805 B
Bash
Raw Normal View History

UPDATE_URL="https://raw.githubusercontent.com/msmhq/msm/master"
wget -q ${UPDATE_URL}/installers/common.sh -O /tmp/msmcommon.sh
2012-11-03 22:35:11 +00:00
source /tmp/msmcommon.sh && rm -f /tmp/msmcommon.sh
function update_system_packages() {
install_log "Updating sources"
2012-11-03 22:20:53 +00:00
sudo apt-get update || install_error "Couldn't update package list"
sudo apt-get upgrade || install_error "Couldn't upgrade packages"
}
function install_dependencies() {
install_log "Installing required packages"
2012-11-03 22:20:53 +00:00
sudo apt-get install screen rsync zip || install_error "Couldn't install dependencies"
}
function enable_init() {
install_log "Enabling automatic startup and shutdown"
hash insserv 2>/dev/null
if [[ $? == 0 ]]; then
2012-11-03 22:20:53 +00:00
sudo insserv msm
else
2012-11-03 22:20:53 +00:00
sudo update-rc.d msm defaults
fi
}
install_msm