We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0062d02 commit 92fda42Copy full SHA for 92fda42
bin/v-restart-system
@@ -11,6 +11,7 @@
11
12
# Argument definition
13
restart=$1
14
+delay=$2
15
16
# Includes
17
source $HESTIA/func/main.sh
@@ -20,7 +21,7 @@ source $HESTIA/func/main.sh
20
21
# Verifications #
22
#----------------------------------------------------------#
23
-check_args '1' "$#" 'RESTART'
24
+check_args '1' "$#" 'RESTART [DELAY]'
25
26
27
# Perform verification if read-only mode is enabled
@@ -31,6 +32,10 @@ check_hestia_demo_mode
31
32
33
34
if [ "$restart" = 'yes' ]; then
35
+ if [ "$delay" ]; then
36
+ echo "The server will restart in $delay seconds..."
37
+ sleep $delay
38
+ fi
39
/sbin/reboot
40
fi
41
0 commit comments