Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #***************************************************
- #! /bin/sh
- # /etc/init.d/autoconnectnet
- ### BEGIN INIT INFO
- # Provides: noip
- # Required-Start: $remote_fs $syslog
- # Required-Stop: $remote_fs $syslog
- # Default-Start: 2 3 4 5
- # Default-Stop: 0 1 6
- # Short-Description: Simple script to start a program at boot
- # Description: A simple script from www.stuffaboutcode.com which will start / stop a program a boot / shutdown.
- ### END INIT INFO
- case "$1" in
- start)
- sleep 10
- echo "connecting via sakis3g"
- # run application you want to start
- sudo /root/3g/sakis3g connect --console --interactive APN=CUSTOM_APN CUSTOM_APN='internet' APN_USER='turkcell' APN_PASS='turkcell' USBINTERFACE=3 USBDRIVER=sierra USBMODEM=12d1:1003 OTHER=USBMODEM MODEM=OTHER
- ;;
- stop)
- echo "dissconnecting via sakis3g"
- # kill application you want to stop
- /opt/sakis3g/sakis3g --sudo "disconnect"
- ;;
- *)
- echo "Usage: /etc/init.d/autoconnectnet {start|stop}"
- exit 1
- ;;
- esac
- exit 0
- #*********************************************************
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement