diff options
author | P. A. López-Valencia | 2015-06-09 17:51:27 -0500 |
---|---|---|
committer | P. A. López-Valencia | 2015-06-09 17:51:27 -0500 |
commit | 3ff3b90139e3f0f34795c44c8fdff924c84f232e (patch) | |
tree | 33aa67261ee30168b20c0095d1668c82f516ff62 | |
download | aur-3ff3b90139e3f0f34795c44c8fdff924c84f232e.tar.gz |
cherokee-git 1.2.104.r5816-2
-rw-r--r-- | .SRCINFO | 40 | ||||
-rw-r--r-- | .gitignore | 15 | ||||
-rw-r--r-- | PKGBUILD | 105 | ||||
-rw-r--r-- | cherokee.logrotate | 9 | ||||
-rw-r--r-- | cherokee.service | 9 |
5 files changed, 178 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..3faa0c030517 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,40 @@ +pkgbase = cherokee-git + pkgdesc = A very fast, flexible and easy to configure Web Server + pkgver = 1.2.104.r5816 + pkgrel = 2 + url = http://www.cherokee-project.com/ + arch = i686 + arch = x86_64 + license = GPL2 + makedepends = libldap + makedepends = pam + makedepends = libmariadbclient + makedepends = php-fpm + makedepends = ffmpeg + makedepends = geoip + makedepends = rrdtool + depends = openssl + depends = pcre + depends = python2 + optdepends = libldap: ldap validator + optdepends = pam: pam validator + optdepends = php-fpm: php5 support + optdepends = libmariadbclient: mysql validator + optdepends = ffmpeg: Audio/Video streaming handler + optdepends = geoip: GeoIP rule module + optdepends = rrdtool: RRDtool based information collector + provides = cherokee + conflicts = cherokee + options = !libtool + backup = etc/cherokee/cherokee.conf + backup = etc/logrotate.d/cherokee + backup = etc/pam.d/cherokee + source = cherokee-git::git+https://github.com/cherokee/webserver.git + source = cherokee.logrotate + source = cherokee.service + sha256sums = SKIP + sha256sums = 20e26d633f8c1cd90eb21f41dd163b73a83846e405b1ce995e072c4efefc522e + sha256sums = 2838afb60dbdfd946c767b8b7170297860baf1638feb7f1075e2d3cf04838407 + +pkgname = cherokee-git + diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..65423b2709cc --- /dev/null +++ b/.gitignore @@ -0,0 +1,15 @@ +*~ +pkg/ +src/ +*.gz +*.bz2 +*.xz +*.lzo +*.xz4 +*.tgz +*.tbz +*.txz +*.tar +*.jar +*.zip +cherokee-git diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..be6ff3a6eead --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,105 @@ +# Maintainer: Please see AUR page for contact info. +# Contributor: Doug Newgard <scimmia22 at outlook dot com> +# Contributor: Fernando Jiménez Solano <fjim at sdfeu dot org> +# Contributor: Evangelos Foutras <evangelos at foutrelis dot com> +# Contributor: Link Dupont <link @ subpop dot net> +# Contributor: Pierre Bourdin <pierre at pi3rrot dot net> +# Contributor: Alexander von Gluck IV <kallisti5 at unixzen dot com> +# Contributor: dieghen89 <dieghen89 at gmail dot com> + +pkgname=cherokee-git +pkgver=1.2.104.r5816 +pkgrel=2 +pkgdesc="A very fast, flexible and easy to configure Web Server" +arch=('i686' 'x86_64') +url="http://www.cherokee-project.com/" +license=('GPL2') +depends=('openssl' 'pcre' 'python2') +makedepends=('libldap' 'pam' 'libmariadbclient' 'php-fpm' 'ffmpeg' 'geoip' 'rrdtool') +optdepends=('libldap: ldap validator' + 'pam: pam validator' + 'php-fpm: php5 support' + 'libmariadbclient: mysql validator' + 'ffmpeg: Audio/Video streaming handler' + 'geoip: GeoIP rule module' + 'rrdtool: RRDtool based information collector') +backup=('etc/cherokee/cherokee.conf' + 'etc/logrotate.d/cherokee' + 'etc/pam.d/cherokee') +options=('!libtool') +provides=('cherokee') +conflicts=('cherokee') +source=( + "$pkgname::git+https://github.com/cherokee/webserver.git" + 'cherokee.logrotate' + 'cherokee.service') +sha256sums=('SKIP' + '20e26d633f8c1cd90eb21f41dd163b73a83846e405b1ce995e072c4efefc522e' + '2838afb60dbdfd946c767b8b7170297860baf1638feb7f1075e2d3cf04838407') + +pkgver() { + cd "$srcdir/$pkgname" + + printf "%s.r%s" \ + "$(git describe --abbrev=0 --tags|sed 's/^v//')" \ + "$(git rev-list --count HEAD)" +} + +prepare() { + cd "$srcdir/$pkgname" + + # Use subdirectory for logs + sed -i -r 's|(%localstatedir%/log)|\1/cherokee|' cherokee.conf.sample.pre + + # Use Python 2 in cherokee-admin + sed -i 's|"python"|"python2"|' cherokee/main_admin.c +} + +build() { + cd "$srcdir/$pkgname" + + ./autogen.sh \ + --prefix=/usr \ + --sysconfdir=/etc \ + --localstatedir=/var \ + --sbindir=/usr/bin \ + --with-wwwroot=/srv/cherokee/http \ + --with-cgiroot=/src/cherokee/cgi-bin \ + --with-wwwuser=http \ + --with-wwwgroup=http \ + --disable-static \ + --with-php=/usr/bin/php-fpm \ + --with-python=/usr/bin/python2 \ + --enable-os-string="Arch Linux" + + make +} + +package() { + cd "$srcdir/$pkgname" + + make DESTDIR="$pkgdir"/ install + + # PAM configuration file for cherokee + install -D -m644 pam.d_cherokee "$pkgdir"/etc/pam.d/cherokee + + # Fix ownership of /var/lib/cherokee/graphs + chown -R http:http "$pkgdir"/var/lib/cherokee/graphs + + # Use Python 2 (mostly fixed upstream, from the Cherokee PKGBUILD) + sed -i 's/env python$/&2/' "$pkgdir"/usr/bin/CTK-run + + # Compile Python scripts + python2 -m compileall "$pkgdir" + python2 -O -m compileall "$pkgdir" + + # Move files to their resting places + install -d -o http -g http "$pkgdir"/var/log/cherokee + install -Dm644 "$srcdir"/cherokee.logrotate "$pkgdir"/etc/logrotate.d/cherokee + install -Dm644 "$srcdir"/cherokee.service "$pkgdir"/usr/lib/systemd/system/cherokee.service + + # It seems /var/run is now owned by filesystem... Ah! The irony. Oh! The pain! + rmdir "$pkgdir"/var/run +} + +# vim: ft=sh:ts=2:sw=2:et diff --git a/cherokee.logrotate b/cherokee.logrotate new file mode 100644 index 000000000000..19207fd02006 --- /dev/null +++ b/cherokee.logrotate @@ -0,0 +1,9 @@ +/var/log/cherokee/*.error /var/log/cherokee/*.access { + daily + rotate 14 + compress + sharedscripts + postrotate + /bin/kill -HUP `cat /var/run/cherokee.pid 2>/dev/null` 2>/dev/null || true + endscript +} diff --git a/cherokee.service b/cherokee.service new file mode 100644 index 000000000000..ab725cc80509 --- /dev/null +++ b/cherokee.service @@ -0,0 +1,9 @@ +[Unit] +Description=Cherokee web server +After=network.target + +[Service] +ExecStart=/usr/bin/cherokee + +[Install] +WantedBy=multi-user.target |