3) You should be able to use the postinstall step to do that. I think in the case you have described you will need two init scripts. One with just a start() to start the app before the LoRa WAN server with an empty stop() that does nothing, and a second script that will be run after the LoRa WAN script that has the stop() defined to stop the app that has an empty start().
Based on the comments above. Instead of creating two brand new scripts, do you see any issues in updating the start priority of customapp script in the init.d folder, as the kill is being done in the correct order, lorawan server first and then the custom app.
if you don’t see any issues, Should I update the priority of the customapp script during the install of my custom app. Since there is only one custom app and I would like it to start before the Lorawan service is up and running?
Again yesterday while testing this we lost a packet just because the custom app launched 20 seconds after the lorawan service.
Thanks,
Ajay