Skip to content

Instantly share code, notes, and snippets.

@mattcuk
Created April 22, 2018 18:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mattcuk/307e361af141953bc42ed6e58d538bc7 to your computer and use it in GitHub Desktop.
Save mattcuk/307e361af141953bc42ed6e58d538bc7 to your computer and use it in GitHub Desktop.
This will make the webserver call as a background task, so control will be given back to the service immediately, rather than it waiting for the wget to complete.
echo Calling energenie socket...
wget --quiet --background --output-document="callenergenie.log" "http://192.168.1.99/callenergenie.php?delay=10&switch=2&state=off"
echo Sleeping for 2 seconds
sleep 2
echo Done.
exit 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment