Skip to content

Commit 51be240

Browse files
author
Serghey Rodin
committed
smarter way to use restart command in other scripts
1 parent 8df1d74 commit 51be240

File tree

8 files changed

+35
-1
lines changed

8 files changed

+35
-1
lines changed

bin/v-list-user-log

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ json_list() {
2424
echo "{"
2525
for str in $logs; do
2626
eval $str
27-
CMD=${CMD//\"/\\\"}
2827
echo -n ' "'$ID'": {
2928
"CMD": "'$CMD'",
3029
"UNDO": "'$UNDO'",

bin/v-restart-cron

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,11 @@ send_email_report() {
3030
# Action #
3131
#----------------------------------------------------------#
3232

33+
# Exit
34+
if [ "$1" = "no" ]; then
35+
exit
36+
fi
37+
3338
# Schedule restart
3439
if [ "$1" = 'scheduled' ]; then
3540
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe

bin/v-restart-dns

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,11 @@ send_email_report() {
3535
# Action #
3636
#----------------------------------------------------------#
3737

38+
# Exit
39+
if [ "$1" = "no" ]; then
40+
exit
41+
fi
42+
3843
# Schedule restart
3944
if [ "$1" = 'scheduled' ]; then
4045
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe

bin/v-restart-ftp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,11 @@ send_email_report() {
3030
# Action #
3131
#----------------------------------------------------------#
3232

33+
# Exit
34+
if [ "$1" = "no" ]; then
35+
exit
36+
fi
37+
3338
# Schedule restart
3439
if [ "$1" = 'scheduled' ]; then
3540
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe

bin/v-restart-mail

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,11 @@ send_email_report() {
3030
# Action #
3131
#----------------------------------------------------------#
3232

33+
# Exit
34+
if [ "$1" = "no" ]; then
35+
exit
36+
fi
37+
3338
# Schedule restart
3439
if [ "$1" = 'scheduled' ]; then
3540
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe

bin/v-restart-proxy

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,11 @@ send_email_report() {
3030
# Action #
3131
#----------------------------------------------------------#
3232

33+
# Exit
34+
if [ "$1" = "no" ]; then
35+
exit
36+
fi
37+
3338
# Schedule restart
3439
if [ "$1" = 'scheduled' ]; then
3540
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe

bin/v-restart-web

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,11 @@ send_email_report() {
3030
# Action #
3131
#----------------------------------------------------------#
3232

33+
# Exit
34+
if [ "$1" = "no" ]; then
35+
exit
36+
fi
37+
3338
# Schedule restart
3439
if [ "$1" = 'scheduled' ]; then
3540
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe

bin/v-restart-web-backend

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,11 @@ send_email_report() {
3030
# Action #
3131
#----------------------------------------------------------#
3232

33+
# Exit
34+
if [ "$1" = "no" ]; then
35+
exit
36+
fi
37+
3338
# Schedule restart
3439
if [ "$1" = 'scheduled' ]; then
3540
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe

0 commit comments

Comments
 (0)