Help with autostart.sh and shutdown.sh not working

Hi everybody, hope everyone is fine on these hard times
I have a problem with the files of the title, they don´t work. I want them to execute a http request
Any help would be great

Thanks

autostart:

#!/bin/sh
( 
sleep 5
  curl -s 'https://autoremotejoaomgcd.appspot.com/sendmessage?key=XXXX&message=Coreelec=:=on' > /dev/null
  /storage/.config/acestream/autostart.sh
)&

shutdown:

case "$1" in
  halt)
    # your commands here
    ;;
  poweroff)
   curl -s 'https://autoremotejoaomgcd.appspot.com/sendmessage?key=xxxxxxx&message=Coreelec=:=off' > /dev/null
    ;;
  reboot)
    # your commands here
    ;;
  *)
    # your commands here
    ;;
esac

Reboot the box, type this command and post link you get to see what is wrong with autoexec.sh.

journalctl -u kodi-autostart -l --no-pager | paste

For shutdown.sh maybe you need to put command under halt ?

You can also run the command manually by placing it in a file and then issuing the command, “filename”.sh
This will tell you whether the script is capable of running before you go fault finding the autostart script.

Shoog

1 Like