Add a default for backup
This commit is contained in:
parent
95030efba2
commit
a9fdb43bf6
|
@ -6,6 +6,9 @@ sleep $((16#$(ip a | grep "link/ether" | head -1 | awk -F ':' '{print $6}' | awk
|
||||||
number_of_full_to_keep="<%= @full_backup_retention %>"
|
number_of_full_to_keep="<%= @full_backup_retention %>"
|
||||||
|
|
||||||
backup="${1}"
|
backup="${1}"
|
||||||
|
if [[ -z ${backup} ]]; then
|
||||||
|
backup="backup1.$(hostname -d)"
|
||||||
|
fi
|
||||||
if ! [[ ${backup} =~ backup1.*sunet.se$ ]]; then
|
if ! [[ ${backup} =~ backup1.*sunet.se$ ]]; then
|
||||||
echo "Usage: ${0} <fqdn of backup server>"
|
echo "Usage: ${0} <fqdn of backup server>"
|
||||||
echo "Example: ${0} backup1.sunet.drive.sunet.se"
|
echo "Example: ${0} backup1.sunet.drive.sunet.se"
|
||||||
|
|
Loading…
Reference in a new issue