aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrancesco Colista <fcolista@alpinelinux.org>2020-05-15 06:37:28 +0000
committerFrancesco Colista <fcolista@alpinelinux.org>2020-05-15 06:37:40 +0000
commit66098e7fe4b491f2c46565223afe4de511820707 (patch)
tree1fc6d181bf926b350ac4ac735c17aae08ff8b112
parent16e467bff9514dd3091cffaff3ad91303a23f961 (diff)
downloadaports-66098e7fe4b491f2c46565223afe4de511820707.tar.gz
aports-66098e7fe4b491f2c46565223afe4de511820707.tar.bz2
aports-66098e7fe4b491f2c46565223afe4de511820707.tar.xz
community/gvmd: improved initd
-rw-r--r--community/gvmd/APKBUILD11
-rw-r--r--community/gvmd/gvmd.initd21
2 files changed, 15 insertions, 17 deletions
diff --git a/community/gvmd/APKBUILD b/community/gvmd/APKBUILD
index f96249349d..e786dc77e1 100644
--- a/community/gvmd/APKBUILD
+++ b/community/gvmd/APKBUILD
@@ -2,14 +2,14 @@
# Maintainer: Francesco Colista <fcolista@alpinelinux.org>
pkgname=gvmd
pkgver=9.0.1
-pkgrel=0
+pkgrel=1
pkgdesc="Greenbone Vulnerability Manager"
url="https://www.openvas.org/"
arch="all"
license="GPL-2.0-or-later"
pkgusers="gvm"
pkggroups="gvm"
-depends="rsync postgresql postgresql-contrib libxslt sed gnutls-utils gvm-libs"
+depends="rsync postgresql postgresql-contrib libxslt sed gnutls-utils gvm-libs perl-xml-twig"
makedepends="cmake gvm-libs-dev clang-dev glib-dev
gpgme-dev libgcrypt-dev graphviz libical-dev
postgresql-dev gnutls-dev
@@ -70,11 +70,10 @@ package() {
mkdir -p "$pkgdir"/var/lib/gvm
mkdir -p "$pkgdir"/var/lib/openvas
mkdir -p "$pkgdir"/var/run/gvmd
- chown -R $pkgusers:$pkggroups "$pkgdir"/var/log/gvm/
- chown -R $pkgusers:$pkggroups "$pkgdir"/var/lib/gvm/
+ chown -R $pkgusers:$pkggroups "$pkgdir"/var/log/gvm
+ chown -R $pkgusers:$pkggroups "$pkgdir"/var/lib/gvm
chown -R $pkgusers:$pkggroups "$pkgdir"/var/lib/openvas
chown -R $pkgusers:$pkggroups "$pkgdir"/var/run/gvmd
-
}
doc() {
@@ -88,7 +87,7 @@ EOF
sha512sums="4c4f0e1fdd2255be1a96967d61d9066d8860aecc5959f04c559b1a248bcc54d9cb75facd0156e223d674f038718f1e8ba0ee6b36cdc8ed88efe480acd1aa54cf gvmd-9.0.1.tar.gz
-71c329f425c92159882dec37317e80d3e5c93abba04ea92b735d2a1d6a156ab5c379fdca5fa9b2816ae1e0f961dbac55b17452d6d1ad41f1dfb317976679cb32 gvmd.initd
+035a46a287dc87329c9f2fd436bbd822cbfea82752558dce356026ecacce1639169e147a7e683663df394c1b0b18576f4dfd72f42966a90ebd54c46cd7a75402 gvmd.initd
63ca41e839e40292e4e6eb93947866ae2626f375353dfc142a9618f5bfb87e843f924e5a2ab3f24b5c30ac1c7c8791a5b323cbe2e88fb3c4cfc9713647f8eec2 gvmd.confd
e1eeef173bfab7c750efcc7faa42cf7a1cfb9e6b137716063f273bc709c1346f11262dadbdb0c49822d885dc00177d8ccb91c0491ddc33cfee0a3827f11908f6 gvmd.logrotate
17df9386fc1dccf2fbe3b8d1fd499171f6681b61afe7b4c11ff9debc008798b31d1d02d59463031482d94e10833f0e71bde27cbbe422f23738c77b7c6ada79d2 greenbone-certdata-sync.conf
diff --git a/community/gvmd/gvmd.initd b/community/gvmd/gvmd.initd
index 72f2067e48..977d830031 100644
--- a/community/gvmd/gvmd.initd
+++ b/community/gvmd/gvmd.initd
@@ -1,21 +1,20 @@
#!/sbin/openrc-run
-# Copyright 1999-2014 Gentoo Foundation
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-# $Id$
+
+: ${GVMD_USER:=gvm}
+: ${GVMD_GROUP:=gvm}
+: ${GVMD_TIMEOUT:=30}
name="Greenbone Vulnerability Manager"
command=/usr/bin/gvmd
-command_args="${GVMD_OPTIONS} ${GVMD_LISTEN_ADDRESS_TCP} ${GVMD_PORT} ${GVMD_SCANNER_HOST} ${GVMD_GNUTLS_PRIORITIES}"
-command_user="gvm"
-pidfile="/var/lib/gvm/${RC_SVCNAME}.pid"
+command_args="--foreground ${GVMD_OPTIONS} ${GVMD_LISTEN_ADDRESS_TCP} ${GVMD_PORT} ${GVMD_SCANNER_HOST} ${GVMD_GNUTLS_PRIORITIES}"
+command_background="true"
+command_user="${GVMD_USER}:${GVMD_GROUP}"
+pidfile="/run/gvmd.pid"
+retry="${GVMD_TIMEOUT}"
depend() {
after bootmisc
need localmount net ospd-openvas
}
-
-start_pre() {
- checkpath --directory --owner $command_user:$command_user --mode 0775 \
- /var/lib/gvm
-}
-