mirror of
https://github.com/serghey-rodin/vesta.git
synced 2025-08-19 13:01:51 -07:00
smarter way to use restart command in other scripts
This commit is contained in:
parent
8df1d74ae3
commit
51be240bd4
8 changed files with 35 additions and 1 deletions
|
@ -24,7 +24,6 @@ json_list() {
|
||||||
echo "{"
|
echo "{"
|
||||||
for str in $logs; do
|
for str in $logs; do
|
||||||
eval $str
|
eval $str
|
||||||
CMD=${CMD//\"/\\\"}
|
|
||||||
echo -n ' "'$ID'": {
|
echo -n ' "'$ID'": {
|
||||||
"CMD": "'$CMD'",
|
"CMD": "'$CMD'",
|
||||||
"UNDO": "'$UNDO'",
|
"UNDO": "'$UNDO'",
|
||||||
|
|
|
@ -30,6 +30,11 @@ send_email_report() {
|
||||||
# Action #
|
# Action #
|
||||||
#----------------------------------------------------------#
|
#----------------------------------------------------------#
|
||||||
|
|
||||||
|
# Exit
|
||||||
|
if [ "$1" = "no" ]; then
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
|
||||||
# Schedule restart
|
# Schedule restart
|
||||||
if [ "$1" = 'scheduled' ]; then
|
if [ "$1" = 'scheduled' ]; then
|
||||||
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe
|
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe
|
||||||
|
|
|
@ -35,6 +35,11 @@ send_email_report() {
|
||||||
# Action #
|
# Action #
|
||||||
#----------------------------------------------------------#
|
#----------------------------------------------------------#
|
||||||
|
|
||||||
|
# Exit
|
||||||
|
if [ "$1" = "no" ]; then
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
|
||||||
# Schedule restart
|
# Schedule restart
|
||||||
if [ "$1" = 'scheduled' ]; then
|
if [ "$1" = 'scheduled' ]; then
|
||||||
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe
|
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe
|
||||||
|
|
|
@ -30,6 +30,11 @@ send_email_report() {
|
||||||
# Action #
|
# Action #
|
||||||
#----------------------------------------------------------#
|
#----------------------------------------------------------#
|
||||||
|
|
||||||
|
# Exit
|
||||||
|
if [ "$1" = "no" ]; then
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
|
||||||
# Schedule restart
|
# Schedule restart
|
||||||
if [ "$1" = 'scheduled' ]; then
|
if [ "$1" = 'scheduled' ]; then
|
||||||
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe
|
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe
|
||||||
|
|
|
@ -30,6 +30,11 @@ send_email_report() {
|
||||||
# Action #
|
# Action #
|
||||||
#----------------------------------------------------------#
|
#----------------------------------------------------------#
|
||||||
|
|
||||||
|
# Exit
|
||||||
|
if [ "$1" = "no" ]; then
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
|
||||||
# Schedule restart
|
# Schedule restart
|
||||||
if [ "$1" = 'scheduled' ]; then
|
if [ "$1" = 'scheduled' ]; then
|
||||||
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe
|
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe
|
||||||
|
|
|
@ -30,6 +30,11 @@ send_email_report() {
|
||||||
# Action #
|
# Action #
|
||||||
#----------------------------------------------------------#
|
#----------------------------------------------------------#
|
||||||
|
|
||||||
|
# Exit
|
||||||
|
if [ "$1" = "no" ]; then
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
|
||||||
# Schedule restart
|
# Schedule restart
|
||||||
if [ "$1" = 'scheduled' ]; then
|
if [ "$1" = 'scheduled' ]; then
|
||||||
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe
|
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe
|
||||||
|
|
|
@ -30,6 +30,11 @@ send_email_report() {
|
||||||
# Action #
|
# Action #
|
||||||
#----------------------------------------------------------#
|
#----------------------------------------------------------#
|
||||||
|
|
||||||
|
# Exit
|
||||||
|
if [ "$1" = "no" ]; then
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
|
||||||
# Schedule restart
|
# Schedule restart
|
||||||
if [ "$1" = 'scheduled' ]; then
|
if [ "$1" = 'scheduled' ]; then
|
||||||
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe
|
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe
|
||||||
|
|
|
@ -30,6 +30,11 @@ send_email_report() {
|
||||||
# Action #
|
# Action #
|
||||||
#----------------------------------------------------------#
|
#----------------------------------------------------------#
|
||||||
|
|
||||||
|
# Exit
|
||||||
|
if [ "$1" = "no" ]; then
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
|
||||||
# Schedule restart
|
# Schedule restart
|
||||||
if [ "$1" = 'scheduled' ]; then
|
if [ "$1" = 'scheduled' ]; then
|
||||||
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe
|
echo "$BIN/$SCRIPT now" >> $VESTA/data/queue/restart.pipe
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue