monkey: simplify directory creation
This commit is contained in:
parent
83c2f7ca79
commit
cd5507e5e8
14
srcpkgs/monkey/files/monkey/run
Executable file → Normal file
14
srcpkgs/monkey/files/monkey/run
Executable file → Normal file
@ -1,16 +1,2 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
[ -s conf ] && . ./conf
|
|
||||||
|
|
||||||
: ${ROOTDIR:=/srv/www/monkey}
|
|
||||||
: ${LOGDIR:=/var/log/monkey}
|
|
||||||
|
|
||||||
if [ ! -d $ROOTDIR ]; then
|
|
||||||
mkdir -p $ROOTDIR
|
|
||||||
chown _monkey:_monkey $ROOTDIR
|
|
||||||
fi
|
|
||||||
if [ ! -d $LOGDIR ]; then
|
|
||||||
mkdir -p $LOGDIR/htdocs
|
|
||||||
chown _monkey:_monkey -R $LOGDIR
|
|
||||||
fi
|
|
||||||
|
|
||||||
exec chpst -u monkey:monkey monkey
|
exec chpst -u monkey:monkey monkey
|
||||||
|
@ -1,15 +1,14 @@
|
|||||||
# Template file for 'monkey'
|
# Template file for 'monkey'
|
||||||
pkgname=monkey
|
pkgname=monkey
|
||||||
version=1.6.9
|
version=1.6.9
|
||||||
revision=1
|
revision=2
|
||||||
build_style=configure
|
build_style=configure
|
||||||
|
configure_args="--prefix=/usr --sbindir=/usr/bin --libdir=/usr/lib
|
||||||
|
--sysconfdir=/etc/monkey/ --enable-plugins=mbedtls --malloc-libc
|
||||||
|
--webroot=/srv/www/$pkgname --mandir=/usr/share/man --default-user=_monkey
|
||||||
|
--pidfile=/var/run/monkey.pid --logdir=/var/log/monkey"
|
||||||
hostmakedepends="cmake"
|
hostmakedepends="cmake"
|
||||||
makedepends="mbedtls-devel"
|
makedepends="mbedtls-devel"
|
||||||
configure_args+="--prefix=/usr --sbindir=/usr/bin --libdir=/usr/lib "
|
|
||||||
configure_args+="--sysconfdir=/etc/monkey/ --enable-plugins=mbedtls "
|
|
||||||
configure_args+="--webroot=/srv/www/$pkgname --mandir=/usr/share/man "
|
|
||||||
configure_args+="--pidfile=/var/run/monkey.pid --logdir=/var/log/monkey "
|
|
||||||
configure_args+="--malloc-libc --default-user=_$pkgname "
|
|
||||||
short_desc="Cross-arch embeddable lightweight HTTP server"
|
short_desc="Cross-arch embeddable lightweight HTTP server"
|
||||||
maintainer="necrophcodr <necrophcodr@necrophcodr.me>"
|
maintainer="necrophcodr <necrophcodr@necrophcodr.me>"
|
||||||
license="Apache-2.0"
|
license="Apache-2.0"
|
||||||
@ -25,8 +24,12 @@ conf_files="
|
|||||||
/etc/monkey/plugins.load
|
/etc/monkey/plugins.load
|
||||||
/etc/monkey/monkey.mime"
|
/etc/monkey/monkey.mime"
|
||||||
|
|
||||||
system_accounts="_$pkgname"
|
system_accounts="_monkey"
|
||||||
_monkey_homedir="/srv/www/$pkgname"
|
_monkey_homedir="/srv/www/_monkey"
|
||||||
|
|
||||||
|
make_dirs="
|
||||||
|
/srv/www/monkey 0755 _monkey _monkey
|
||||||
|
/var/log/monkey/htdocs 0755 _monkey _monkey"
|
||||||
|
|
||||||
case $XBPS_TARGET_MACHINE in
|
case $XBPS_TARGET_MACHINE in
|
||||||
*-musl) configure_args+="--musl-mode --no-backtrace ";;
|
*-musl) configure_args+="--musl-mode --no-backtrace ";;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user