-
Notifications
You must be signed in to change notification settings - Fork 211
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
wscat returns nothing when launced from a cron @reboot #141
Comments
I don't know, if the script works when run manually it should also work when run as a cron job. Check if the server receives the message. If you don't control it use another one. Also check the crontab |
Thanks for your answer. I echoed the path variable in the script. I also added "which wscat" command that returns in both case the correct path... |
I can confirm this behaviour. |
Hello,
I want to notify the reboot of a raspberry pi to another server using wscat.
I wrote this script:
--> it works well from command line with and without sudo. The server returns "ok" and the script stops before entering the loop.
-->When launched from this cronjob :
@reboot /home/pi/xxxxxxxx/rebootNotify.sh
Nothing is returned from the wscat command, the script enters infinitly the loop (The loop exists in case
unavailable network at reboot time. BTW, adding a sleep in the cron before calling the scripts leads to the same
result).
Where is the bug?
note : wscat has been installed using sudo npm install -g wscat.
Thanks
Julien
The text was updated successfully, but these errors were encountered: