diff options
author | Francesco Colista <francesco.colista@gmail.com> | 2013-02-28 18:50:09 +0000 |
---|---|---|
committer | Francesco Colista <francesco.colista@gmail.com> | 2013-02-28 18:50:09 +0000 |
commit | ef3ce7bd1808cc82dab605f3754dc6f4407c97e8 (patch) | |
tree | 4431973f430c98472e1f2c45d0fccf7298d9b969 /testing | |
parent | f159beedd116355d2d77e6cbc50cf950755d0928 (diff) | |
download | aports-ef3ce7bd1808cc82dab605f3754dc6f4407c97e8.tar.bz2 aports-ef3ce7bd1808cc82dab605f3754dc6f4407c97e8.tar.xz |
testing/atheme-iris: new apkbuild. Fixes #1462
Diffstat (limited to 'testing')
-rw-r--r-- | testing/atheme-iris/APKBUILD | 55 | ||||
-rw-r--r-- | testing/atheme-iris/atheme-iris.confd | 6 | ||||
-rwxr-xr-x | testing/atheme-iris/atheme-iris.initd | 42 | ||||
-rw-r--r-- | testing/atheme-iris/atheme-iris.post-install | 8 | ||||
-rw-r--r-- | testing/atheme-iris/atheme-iris.pre-install | 4 |
5 files changed, 115 insertions, 0 deletions
diff --git a/testing/atheme-iris/APKBUILD b/testing/atheme-iris/APKBUILD new file mode 100644 index 0000000000..4b05418dc4 --- /dev/null +++ b/testing/atheme-iris/APKBUILD @@ -0,0 +1,55 @@ +# Contributor: Francesco Colista <francesco.colista@gmail.com> +# Maintainer: Francesco Colista <francesco.colista@gmail.com> +pkgname=atheme-iris +pkgver=0_git20130227 +pkgrel=0 +pkgdesc="AJAX IRC client. It is a drop-in replacement for qwebirc." +url="http://www.atheme.net/iris.html" +arch="noarch" +license="GPL" +depends="py-twisted py-twisted-names py-twisted-mail py-twisted-web \ + py-twisted-words py-simplejson py-openssl py-zope-interface" +depends_dev="" +makedepends="$depends_dev python-dev" +install="$pkgname.post-install $pkgname.pre-install" +subpackages="" +source="http://dev.alpinelinux.org/archive/$pkgname/$pkgname-$pkgver.tar.gz + $pkgname.initd + $pkgname.confd" +pkgusers="iris" +pkggroups="iris" +_builddir="$srcdir"/$pkgname-$pkgver +giturl="git://github.com/atheme/iris.git" +disturl="dev.alpinelinux.org:/archive/$pkgname" +build() { + cd "$_builddir" + return 0 +} + +package() { + cd "$_builddir" + mkdir -p $pkgdir/etc/$pkgname + mkdir -p $pkgdir/var/lib/$pkgname + mkdir -p $pkgdir/var/log/$pkgname + mkdir -p $pkgdir/etc/conf.d + mkdir -p $pkgdir/etc/init.d + mkdir -p $pkgdir/var/run/$pkgname + cp "$srcdir"/$pkgname.confd $pkgdir/etc/conf.d/$pkgname + cp "$srcdir"/$pkgname.initd $pkgdir/etc/init.d/$pkgname + cp -r * $pkgdir/var/lib/$pkgname + cp iris.conf.example $pkgdir/etc/$pkgname/iris.conf + ln -s /etc/$pkgname/iris.conf $pkgdir/var/lib/$pkgname/iris.conf + chown iris:iris $pkgdir/var/log/$pkgname + chown iris:iris $pkgdir/var/run/$pkgname + chown -R iris:iris $pkgdir/var/lib/$pkgname +} + +md5sums="b1673663f8891a69a0c746cd3fb0098e atheme-iris-0_git20130227.tar.gz +2e28fb06e4d237ae10f633185ddaf1dc atheme-iris.initd +cb92c7f09b3f8ed203aef46f1ef25a29 atheme-iris.confd" +sha256sums="e6a61f2a50e22dfea06d4e1aef321dd2e1e320f59feb59f2c69e3a45435723e6 atheme-iris-0_git20130227.tar.gz +3f5f889df409dead4f50d5a671813d104660e61ebe840f9e00dbc8b990011408 atheme-iris.initd +708edb2a717e016882d3583b951b63a97fbc48ee769437db74b155a357ad34d7 atheme-iris.confd" +sha512sums="6c1cc6a4faf4fae71fe1b9ac5c53cf099e842114548ba8b746d7facd31d3b9bfec0f212a9a41a1046be77857d04fc0bcdc110c115cbaa876917f861130d58b36 atheme-iris-0_git20130227.tar.gz +af08503060dfe5d66c62dc47515321140cc3920fa082e83102f40ad511977bf1dd683a79922ddb507bbca5a6dba987a5481a7e62ea02e7a94e900bb2c83f9aee atheme-iris.initd +5bd29bc0d46387d15e9f2bcdc5ac66ec6f8e1e1d821a36a5440253ad362df46728278410d1b0f172540713d63be58a92b487d226f91353cb1997e93bfb6d2d9a atheme-iris.confd" diff --git a/testing/atheme-iris/atheme-iris.confd b/testing/atheme-iris/atheme-iris.confd new file mode 100644 index 0000000000..69a548e151 --- /dev/null +++ b/testing/atheme-iris/atheme-iris.confd @@ -0,0 +1,6 @@ +SVCHOME="/var/lib/atheme-iris" +SVCPID="/var/run/atheme-iris/atheme-iris.pid" +LOGFILE="/var/log/atheme-iris/atheme-iris.log" +PORT="9090" +IP="0.0.0.0" +ARGS="-p ${PORT} -i ${IP} -l ${LOGFILE} -P ${SVCPID}" diff --git a/testing/atheme-iris/atheme-iris.initd b/testing/atheme-iris/atheme-iris.initd new file mode 100755 index 0000000000..e0b371c792 --- /dev/null +++ b/testing/atheme-iris/atheme-iris.initd @@ -0,0 +1,42 @@ +#!/sbin/runscript +# Copyright 2013 Alpine Linux +# Distributed under the terms of the GNU General Public License v2 + +extra_stopped_commands="setup" + +depend() { + use net + need localmount +} + +setup() { + ebegin "Setting up ${SVCNAME}" + cd /var/lib/atheme-iris + python ./clean.py + python ./compile.py + echo "atheme-iris has been compiled succesfully." + echo "Now you can start the daemon with /etc/init.d/atheme-iris start" + eend $? +} + +start() { + ebegin "Starting ${SVCNAME}" + if [ -f /var/lib/atheme-iris/.compiled ]; then + cd ${SVCHOME} + nohup python ./run.py ${ARGS} &>/dev/null & + else + eerror "You must first run /etc/init.d/atheme-iris setup" + fi + setup() + eend $? +} + +stop() { + ebegin "Stopping ${SVCNAME}" + if [ -f /var/run/atheme-iris/atheme-iris.pid ]; then + kill $(cat /var/run/atheme-iris/atheme-iris.pid) + else + eerror "atheme-iris is not running." + fi + eend $? +} diff --git a/testing/atheme-iris/atheme-iris.post-install b/testing/atheme-iris/atheme-iris.post-install new file mode 100644 index 0000000000..18a6f7a6e1 --- /dev/null +++ b/testing/atheme-iris/atheme-iris.post-install @@ -0,0 +1,8 @@ +#!/bin/sh +echo "************************************************************************************************" +echo "***** Before starting atheme-iris, you need to: *****" +echo "***** *****" +echo "***** 1 - Modify /etc/atheme-iris/iris.conf *****" +echo "***** 2 - make a symlink from /etc/atheme-iris/iris.conf to /var/lib/atheme-iris/iris.conf *****" +echo "***** 3 - Run /etc/init.d/atheme-iris setup *****" +echo "************************************************************************************************" diff --git a/testing/atheme-iris/atheme-iris.pre-install b/testing/atheme-iris/atheme-iris.pre-install new file mode 100644 index 0000000000..ce32243397 --- /dev/null +++ b/testing/atheme-iris/atheme-iris.pre-install @@ -0,0 +1,4 @@ +#!/bin/sh +adduser -H -h /usr/share/webapps/atheme-iris -g iris -D -s /bin/false iris >/dev/null +exit 0 + |