The Little Guy Posted August 11, 2010 Share Posted August 11, 2010 I have a python script that I made, and I would like it to automatically startup when the server starts up. How can I do something like this? Quote Link to comment https://forums.phpfreaks.com/topic/210418-autostart-python-script/ Share on other sites More sharing options...
trq Posted August 11, 2010 Share Posted August 11, 2010 If its a simple script place a call to it within /etc/rc.local or (for something more complex eg a deamon) write a proper rc script and place it within /etc/init.d (there will already be plenty of examples in there) Quote Link to comment https://forums.phpfreaks.com/topic/210418-autostart-python-script/#findComment-1097968 Share on other sites More sharing options...
The Little Guy Posted August 11, 2010 Author Share Posted August 11, 2010 Thanks! here is what I found: http://wiki.linuxquestions.org/wiki/Rc_script I assume that is a good script to use. Quote Link to comment https://forums.phpfreaks.com/topic/210418-autostart-python-script/#findComment-1097975 Share on other sites More sharing options...
trq Posted August 11, 2010 Share Posted August 11, 2010 I assume that is a good script to use It will depend on your distro but there is likely an example within /etc/{init,rc}.d or you should read some docs specific to your distro. Quote Link to comment https://forums.phpfreaks.com/topic/210418-autostart-python-script/#findComment-1097990 Share on other sites More sharing options...
steviewdr Posted August 14, 2010 Share Posted August 14, 2010 You can use a @reboot in roots crontab. You can also edit /etc/rc.local and add in your script there to run. -steve Quote Link to comment https://forums.phpfreaks.com/topic/210418-autostart-python-script/#findComment-1099389 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.