I have a sixfab 4G LTE shield and the module
through which I connect my RPi to cellular data. It requires few commands to be executed in order to connect. How do I make it run only once post startup of RPi each time RPi boots. Tried using bash script but it keeps executing the task continuously. * OS in use : Raspbian Stretch * Raspberry Pi 3B+
Tried putting the commnads in /etc/init.d but it doesn't work as
sudo pppd call gprs after execution does not provide a way to execute some other command without opening a new tab.
I call "sudo pppd call gprs" to run this command. But the issue is I also have to run "sudo route add default ppp0" so that RPi starts connecting to internet using cellular, how do I achieve the route add default task permanently and only execute "call gprs" everytime at boot(this boot part using systemctl)?
EDIT:
In short: how do i make RPi connect to Internet over ppp0 only by default instead of executing sudo route add default