8 lines
No EOL
270 B
Bash
8 lines
No EOL
270 B
Bash
#!/bin/bash
|
|
|
|
while [ 1 -gt 0 ]; do
|
|
sleep 15
|
|
OUTPUT=( $(echo $(upsc nutdev1@192.168.6.211)) )
|
|
echo "{\"data\": \"${OUTPUT[*]//[$'\t\r\n ']}\"}" | \
|
|
curl -H "Content-Type: application/json" -X POST -d @- http://powerpanel-webview:3555/api/upsc_handler
|
|
done |