Skip to content
Snippets Groups Projects
Commit 3f855856 authored by hench's avatar hench
Browse files

Abort on linux platform if rclone/age is not found

parent 0e8d7bb0
No related branches found
No related tags found
No related merge requests found
...@@ -102,8 +102,17 @@ elif [ $HOST_OS = 'Linux' ]; then ...@@ -102,8 +102,17 @@ elif [ $HOST_OS = 'Linux' ]; then
NOTIFY0='notify-send -a "DTU Compute backup script" -i network-transmit "Backup done"' NOTIFY0='notify-send -a "DTU Compute backup script" -i network-transmit "Backup done"'
NOTIFY1='notify-send -a "DTU Compute backup script" -i network-error "Backup did not complete"' NOTIFY1='notify-send -a "DTU Compute backup script" -i network-error "Backup did not complete"'
# Check for necessary programs - XXX resolve / provide solution # Check for necessary programs - XXX resolve / provide solution
which rclone &>/dev/null || echo -e "\nrclone command not installed\n" which rclone &>/dev/null
which age &>/dev/null || echo -e "\nage command not installed\n" if [ $? -ne 0 ] ; then
echo -e "\nrclone command not installed\n"
exit 1
fi
which age &>/dev/null
if [ $? -ne 0 ] ; then
echo -e "\nrage command not installed\n"
exit 1
fi
# SYSTEMD # SYSTEMD
which systemctl &>/dev/null which systemctl &>/dev/null
if [ $? -ne 0 ]; then if [ $? -ne 0 ]; then
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment