diff options
author | Francesco Colista <fcolista@alpinelinux.org> | 2015-07-22 13:42:22 +0000 |
---|---|---|
committer | Francesco Colista <fcolista@alpinelinux.org> | 2015-07-22 13:42:27 +0000 |
commit | f1e30124267714748882756a524c3add80b3bfa5 (patch) | |
tree | a545c9876a5eba7ccd62507e53eecbcf6e07280f /main | |
parent | f85ee286dbd43e3208e518671a2807e77fb45630 (diff) | |
download | aports-f1e30124267714748882756a524c3add80b3bfa5.tar.bz2 aports-f1e30124267714748882756a524c3add80b3bfa5.tar.xz |
main/mini_httpd: runs with minihttpd user and www-data group
Diffstat (limited to 'main')
-rw-r--r-- | main/mini_httpd/APKBUILD | 2 | ||||
-rw-r--r-- | main/mini_httpd/mini_httpd.conf.sample | 2 | ||||
-rw-r--r-- | main/mini_httpd/mini_httpd.pre-install | 6 |
3 files changed, 8 insertions, 2 deletions
diff --git a/main/mini_httpd/APKBUILD b/main/mini_httpd/APKBUILD index 4315ba58d6..a8dbd85bd1 100644 --- a/main/mini_httpd/APKBUILD +++ b/main/mini_httpd/APKBUILD @@ -1,7 +1,7 @@ # Maintainer: Natanael Copa <ncopa@alpinelinux.org> pkgname=mini_httpd pkgver=1.21 -pkgrel=0 +pkgrel=1 pkgdesc="Small forking webserver with ssl and ipv6 support" url="http://www.acme.com/software/mini_httpd/" arch="all" diff --git a/main/mini_httpd/mini_httpd.conf.sample b/main/mini_httpd/mini_httpd.conf.sample index 0ca98e0e88..ea14301190 100644 --- a/main/mini_httpd/mini_httpd.conf.sample +++ b/main/mini_httpd/mini_httpd.conf.sample @@ -11,7 +11,7 @@ #host=www.example.org port=80 #port=443 -user=nobody +user=minihttpd ## ## The DOCROOT dir=/var/www/localhost/htdocs diff --git a/main/mini_httpd/mini_httpd.pre-install b/main/mini_httpd/mini_httpd.pre-install index 6f8eaae18c..d84f0b7718 100644 --- a/main/mini_httpd/mini_httpd.pre-install +++ b/main/mini_httpd/mini_httpd.pre-install @@ -6,4 +6,10 @@ if [ -f /etc/mini_httpd.conf ] && ! [ -L /etc/mini_httpd.conf ]; then mv /etc/mini_httpd.conf /etc/mini_httpd/mini_httpd.conf \ && ln -s mini_httpd/mini_httpd.conf /etc/mini_httpd.conf fi + +addgroup -g 82 -S www-data 2>/dev/null +adduser -S -H -h /var/www/localhost/htdocs -s /sbin/nologin \ + -D minihttpd 2>/dev/null +addgroup minihttpd www-data 2>/dev/null + exit 0 |