diff options
author | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
---|---|---|
committer | V3n3RiX <venerix@redcorelinux.org> | 2017-10-09 18:53:29 +0100 |
commit | 4f2d7949f03e1c198bc888f2d05f421d35c57e21 (patch) | |
tree | ba5f07bf3f9d22d82e54a462313f5d244036c768 /net-analyzer/greenbone-security-assistant/files |
reinit the tree, so we can have metadata
Diffstat (limited to 'net-analyzer/greenbone-security-assistant/files')
7 files changed, 93 insertions, 0 deletions
diff --git a/net-analyzer/greenbone-security-assistant/files/greenbone-security-assistant-5.0.3-run.patch b/net-analyzer/greenbone-security-assistant/files/greenbone-security-assistant-5.0.3-run.patch new file mode 100644 index 000000000000..ec5ee92fd73b --- /dev/null +++ b/net-analyzer/greenbone-security-assistant/files/greenbone-security-assistant-5.0.3-run.patch @@ -0,0 +1,16 @@ + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 67cf344..c15f785 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -272,7 +272,7 @@ endif (NOT DATADIR) + + set (OPENVAS_STATE_DIR "${LOCALSTATEDIR}/lib/openvas") + set (OPENVAS_LOG_DIR "${LOCALSTATEDIR}/log/openvas") +-set (GSAD_PID_DIR "${LOCALSTATEDIR}/run") ++set (GSAD_PID_DIR "/run") + set (GSA_DATA_DIR "${DATADIR}/openvas/gsa") + + # TODO: Eventually use own certificates diff --git a/net-analyzer/greenbone-security-assistant/files/gsad b/net-analyzer/greenbone-security-assistant/files/gsad new file mode 100644 index 000000000000..f5d76179a55b --- /dev/null +++ b/net-analyzer/greenbone-security-assistant/files/gsad @@ -0,0 +1,22 @@ +#!/sbin/openrc-run +# Copyright 1999-2012 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +depend() { + need net +} + +start() { + ebegin "Starting Greenbone Security Assistant Daemon" + start-stop-daemon --start --name gsad \ + --exec /usr/sbin/gsad \ + --pidfile /var/run/gsad.pid + eend $? +} + +stop() { + ebegin "Stop openvassd" + start-stop-daemon --stop --name gsad \ + --pidfile /var/run/gsad.pid + eend $? +} diff --git a/net-analyzer/greenbone-security-assistant/files/gsad-daemon.conf b/net-analyzer/greenbone-security-assistant/files/gsad-daemon.conf new file mode 100644 index 000000000000..0de530635122 --- /dev/null +++ b/net-analyzer/greenbone-security-assistant/files/gsad-daemon.conf @@ -0,0 +1,14 @@ +#Listen on given address - by default assistant listens on all addresses +# ASSISTANT_LISTEN=--listen=127.0.0.1 + +#Listen on given port - by default 9391 +#ASSISTANT_PORT=--port=9392 + +#Contact manager on given address +#MANAGER_LISTEN=--mlisten=127.0.0.1 + +#Manager listens on given port - by default 9390 +#MANAGER_PORT=--mport=9390 + +# Additional arguments +# ASSISTANT_EXTRA_ARGS="" diff --git a/net-analyzer/greenbone-security-assistant/files/gsad.init b/net-analyzer/greenbone-security-assistant/files/gsad.init new file mode 100644 index 000000000000..df69f2fb7f88 --- /dev/null +++ b/net-analyzer/greenbone-security-assistant/files/gsad.init @@ -0,0 +1,13 @@ +#!/sbin/openrc-run +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +name="Greenbone Security Assistant Daemon" +command="/usr/sbin/gsad" +command_args="${ASSISTANT_LISTEN} ${ASSISTANT_PORT} ${MANAGER_LISTEN} ${MANAGER_PORT} ${ASSISTANT_EXTRA_ARGS}" +pidfile="/run/gsad.pid" + +depend() { + after bootmisc + need localmount net openvasmd +} diff --git a/net-analyzer/greenbone-security-assistant/files/gsad.logrotate b/net-analyzer/greenbone-security-assistant/files/gsad.logrotate new file mode 100644 index 000000000000..f0948cbea1f5 --- /dev/null +++ b/net-analyzer/greenbone-security-assistant/files/gsad.logrotate @@ -0,0 +1,11 @@ +# logrotate for openvas +/var/log/openvas/gsad.log { + rotate 4 + weekly + compress + delaycompress + missingok + postrotate + /bin/kill -HUP `pidof gsad` + endscript +} diff --git a/net-analyzer/greenbone-security-assistant/files/gsad.service b/net-analyzer/greenbone-security-assistant/files/gsad.service new file mode 100644 index 000000000000..8825f52f0949 --- /dev/null +++ b/net-analyzer/greenbone-security-assistant/files/gsad.service @@ -0,0 +1,16 @@ +[Unit] +Description=Greenbone Security Assistant Daemon +After=network.target +Before=openvasmd.service + +[Service] +EnvironmentFile=-/etc/openvas/gsad-daemon.conf +ExecStart=/usr/sbin/gsad -f ${ASSISTANT_LISTEN} ${ASSISTANT_PORT} ${MANAGER_LISTEN} ${MANAGER_PORT} ${ASSISTANT_EXTRA_ARGS} +Restart=always +RestartSec=1 +User=root +Group=root +TimeoutSec=1200 + +[Install] +WantedBy=multi-user.target diff --git a/net-analyzer/greenbone-security-assistant/files/gsad.tmpfiles.d b/net-analyzer/greenbone-security-assistant/files/gsad.tmpfiles.d new file mode 100644 index 000000000000..18e820caec1b --- /dev/null +++ b/net-analyzer/greenbone-security-assistant/files/gsad.tmpfiles.d @@ -0,0 +1 @@ +d /var/cache/openvassd 0775 |