Skip to content

Instantly share code, notes, and snippets.

@song940
Created November 11, 2013 03:53
Show Gist options
  • Save song940/7407562 to your computer and use it in GitHub Desktop.
Save song940/7407562 to your computer and use it in GitHub Desktop.
Making scripts run at boot time with Debian
#! /bin/sh
# /etc/init.d/blah
#
# Some things that run always
touch /var/lock/blah
# Carry out specific functions when asked to by the system
case "$1" in
start)
echo "Starting script blah "
echo "Could do more here"
;;
stop)
echo "Stopping script blah"
echo "Could do more here"
;;
*)
echo "Usage: /etc/init.d/blah {start|stop}"
exit 1
;;
esac
exit 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment