Commit ddac259a authored by Natanael Copa's avatar Natanael Copa
Browse files

testing/kamailio: fix userid and de-bashify

parent 9d6a9145
# Contributor: Michael Mason <ms13sp@gmail.com>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=kamailio
pkgver=1.5.2
pkgrel=2
pkgrel=3
pkgdesc="Open Source SIP Server"
url="http://www.kamailio.org/"
pkgusers="kamailio"
pkggroups="kamailio"
license="GPL"
depends=
makedepends="bison flex expat-dev postgresql-dev mysql-dev pcre-dev
......@@ -25,9 +28,13 @@ build() {
cd scripts
sed -i -e 's:/var/run/kamailio.pid:/var/run/kamailio/kamailio.pid:g' \
kamctl.base kamctlrc || return 1
# we actually dont need bash
sed -i -e '1s:/bin/bash:/bin/sh:' kamctl kamdbctl \
|| return 1
cd ..
make prefix=/usr \
cfg-dir=/etc/kamailio \
MODS_MYSQL=yes \
MODS_PCRE=yes \
MODS_PRESENCE=yes \
......@@ -36,6 +43,7 @@ build() {
include_modules=db_postgres \
all || return 1
make prefix=/usr \
cfg-dir=/etc/kamailio \
MODS_MYSQL=yes \
MODS_PCRE=yes \
MODS_PRESENCE=yes \
......@@ -45,6 +53,7 @@ build() {
basedir="$pkgdir" install || return 1
install -m755 -D "$srcdir"/$pkgname.initd "$pkgdir"/etc/init.d/$pkgname
install -d -o kamailio "$pkgdir"/var/run/kamailio
}
_mv_mod() {
......@@ -87,6 +96,6 @@ presence() {
}
md5sums="6c6f4ed6fbcb4d008b8ac3de5b99ce99 kamailio-1.5.2-notls_src.tar.gz
e6b93397ec2a1ec094d23d93d87771bd kamailio.initd
84f3c403b65a8fca9df4b71f51224e21 kamailio.initd
c646af2dd31f5c4289a2f802c873d98f kamailio.pre-install
3fbaf633ff1620d0d526fc4047c7bed9 kamailio.post-install"
......@@ -11,8 +11,8 @@ start() {
ebegin "Starting Kamailio"
start-stop-daemon --start --quiet --pidfile $pidfile --exec $daemon \
-- \
-u ${KAMAILIO_USER:-opensips} \
-g ${KAMAILIO_GROUP:-opensips} \
-u ${KAMAILIO_USER:-kamailio} \
-g ${KAMAILIO_GROUP:-kamailio} \
-P $pidfile
eend $?
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment