How do you package a Python app with setuptools so that when it's installed (e.g. via setup.py or pip), it places a daemon script in the appropriate location, starts it, and marks it to automatically start at boot time?
In my case, my code only works with Linux, so I only care about installing the daemon in Linux environments (specifically Ubuntu).
I've found several posts describing how to easily create Python daemons, but I can't seem to find anything describing how you'd install them in a production environment so that they'd be treated as any other normal daemon or service.
I know Ubuntu and some other distros keep their daemons in /etc/init.d, and I know how to use setuptools to copy files to specific locations on the filesystem, so would it be safe to copy or symlink my script to /etc/init.d and then run chkconfig to set it's runtime, or is there a more safe distribution-neutral way of installing daemons?