|
|
@ -1,4 +1,4 @@ |
|
|
|
#!/bin/bash |
|
|
|
#!/bin/bas |
|
|
|
|
|
|
|
|
|
|
|
logDate=$(date '+%Y-%m-%dT%TZ') |
|
|
|
logDate=$(date '+%Y-%m-%dT%TZ') |
|
|
|
logFile="/home/lm-1/logs/shutdown-logs.txt" |
|
|
|
logFile="/home/lm-1/logs/shutdown-logs.txt" |
|
|
@ -26,4 +26,5 @@ getApiUrl |
|
|
|
|
|
|
|
|
|
|
|
curl -X POST --header 'Content-Type: application/json' --header 'Accept: text/html' -d '{"status": "off", "time": "'${logDate}'", "token": "QWERTYuiopasdfghjklzxcvbnm_1234567890"}' "${apiURL}" |
|
|
|
curl -X POST --header 'Content-Type: application/json' --header 'Accept: text/html' -d '{"status": "off", "time": "'${logDate}'", "token": "QWERTYuiopasdfghjklzxcvbnm_1234567890"}' "${apiURL}" |
|
|
|
|
|
|
|
|
|
|
|
shutdown now |
|
|
|
sleep 5 |
|
|
|
|
|
|
|
shutdown now |
|
|
|