Skip to content

Commit 17c2088

Browse files
committed
autoupdates + fqdn workaround
1 parent 29fc164 commit 17c2088

File tree

3 files changed

+30
-0
lines changed

3 files changed

+30
-0
lines changed

install/vst-install-debian.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -380,6 +380,13 @@ if [ -z "$servername" ]; then
380380
servername=$(hostname -f)
381381
fi
382382

383+
# Set FQND if it wasn't set
384+
mask1='(([[:alnum:]](-?[[:alnum:]])*)\.)'
385+
mask2='*[[:alnum:]](-?[[:alnum:]])+\.[[:alnum:]]{2,}'
386+
if ! [[ "$servername" =~ ^${mask1}${mask2}$ ]]; then
387+
servername="$servername.example.com"
388+
fi
389+
383390
# Set email if it wasn't set
384391
if [ -z "$email" ]; then
385392
email="admin@$servername"
@@ -1182,6 +1189,9 @@ check_result $? "vesta start failed"
11821189
# Adding notifications
11831190
$VESTA/upd/add_notifications.sh
11841191

1192+
# Adding cronjob for autoupdates
1193+
$VESTA/bin/v-add-cron-vesta-autoupdate
1194+
11851195

11861196
#----------------------------------------------------------#
11871197
# Vesta Access Info #

install/vst-install-rhel.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -380,6 +380,13 @@ if [ -z "$servername" ]; then
380380
servername=$(hostname -f)
381381
fi
382382

383+
# Set FQND if it wasn't set
384+
mask1='(([[:alnum:]](-?[[:alnum:]])*)\.)'
385+
mask2='*[[:alnum:]](-?[[:alnum:]])+\.[[:alnum:]]{2,}'
386+
if ! [[ "$servername" =~ ^${mask1}${mask2}$ ]]; then
387+
servername="$servername.example.com"
388+
fi
389+
383390
# Set email if it wasn't set
384391
if [ -z "$email" ]; then
385392
email="admin@$servername"
@@ -1252,6 +1259,9 @@ check_result $? "vesta start failed"
12521259
# Adding notifications
12531260
$VESTA/upd/add_notifications.sh
12541261

1262+
# Adding cronjob for autoupdates
1263+
$VESTA/bin/v-add-cron-vesta-autoupdate
1264+
12551265

12561266
#----------------------------------------------------------#
12571267
# Vesta Access Info #

install/vst-install-ubuntu.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -365,6 +365,13 @@ if [ -z "$servername" ]; then
365365
servername=$(hostname -f)
366366
fi
367367

368+
# Set FQND if it wasn't set
369+
mask1='(([[:alnum:]](-?[[:alnum:]])*)\.)'
370+
mask2='*[[:alnum:]](-?[[:alnum:]])+\.[[:alnum:]]{2,}'
371+
if ! [[ "$servername" =~ ^${mask1}${mask2}$ ]]; then
372+
servername="$servername.example.com"
373+
fi
374+
368375
# Set email if it wasn't set
369376
if [ -z "$email" ]; then
370377
email="admin@$servername"
@@ -1171,6 +1178,9 @@ check_result $? "vesta start failed"
11711178
# Adding notifications
11721179
$VESTA/upd/add_notifications.sh
11731180

1181+
# Adding cronjob for autoupdates
1182+
$VESTA/bin/v-add-cron-vesta-autoupdate
1183+
11741184

11751185
#----------------------------------------------------------#
11761186
# Vesta Access Info #

0 commit comments

Comments
 (0)