versatica / OverSIP

OverSIP: the SIP framework you dreamed about
http://oversip.versatica.com
Other
342 stars 69 forks source link

Create packages for Centos, RedHat, *BSD... #8

Open ibc opened 11 years ago

ibc commented 11 years ago

Currently just a DEB package is provided for automatic installation. We need to also provide RMP packages and so on so they automatically install the oversip gem along with init scripts (like the DEB package does).

Can you help on this?

jaxyeh commented 11 years ago

Inaki, you might want to check out the FPM tool used to generate RPM builds. I've successfully used this tool to generate deb + rpm builds for Ubuntu 12.04, CentOS/RHEL/Fedora, etc...

ibc commented 11 years ago

Thanks, I'll take a look to it.

franx commented 11 years ago

here a generic CentOS/RHEL/Fedora init script for oversip.


!/bin/sh

chkconfig: - 85 15

PID="--pid /var/run/oversip/oversip.pid -u oversip";

if [ ! -d /var/run/oversip ]; then mkdir -p /var/run/oversip fi

if id -u oversip >/dev/null 2>&1; then echo "Switch to user oversip"; else adduser -u 106 -g 99 --shell /bin/false -b /var/run oversip chown oversip /var/run/oversip fi

. /etc/rc.d/init.d/functions

case "$1" in start) echo -n "Starting oversip: " daemon oversip $PID echo touch /var/lock/subsys/oversip ;; stop) echo -n "Shutting down oversip ??: " killproc oversip echo rm -f /var/lock/subsys/oversip ;; status) status oversip ;; condrestart) if [ -f /var/lock/subsys/oversip ]; then $0 stop $0 start fi ;; reload|restart) $0 stop $0 start echo "destroy existing connections during a restart." ;; *) echo "Usage: $0 {start|stop|restart|status}" exit 1 esac

exit 0


hope it helps.

tejastank commented 8 years ago

+1