summaryrefslogtreecommitdiff
path: root/roles/greenbone/server
diff options
context:
space:
mode:
Diffstat (limited to 'roles/greenbone/server')
-rw-r--r--roles/greenbone/server/templates/docker-compose-22.4.yml.j2123
1 files changed, 84 insertions, 39 deletions
diff --git a/roles/greenbone/server/templates/docker-compose-22.4.yml.j2 b/roles/greenbone/server/templates/docker-compose-22.4.yml.j2
index 85742836..8c007ee9 100644
--- a/roles/greenbone/server/templates/docker-compose-22.4.yml.j2
+++ b/roles/greenbone/server/templates/docker-compose-22.4.yml.j2
@@ -1,65 +1,65 @@
services:
vulnerability-tests:
- image: greenbone/vulnerability-tests
+ image: registry.community.greenbone.net/community/vulnerability-tests
environment:
STORAGE_PATH: /var/lib/openvas/22.04/vt-data/nasl
volumes:
- vt_data_vol:/mnt
notus-data:
- image: greenbone/notus-data
+ image: registry.community.greenbone.net/community/notus-data
volumes:
- notus_data_vol:/mnt
scap-data:
- image: greenbone/scap-data
+ image: registry.community.greenbone.net/community/scap-data
volumes:
- scap_data_vol:/mnt
cert-bund-data:
- image: greenbone/cert-bund-data
+ image: registry.community.greenbone.net/community/cert-bund-data
volumes:
- cert_data_vol:/mnt
dfn-cert-data:
- image: greenbone/dfn-cert-data
+ image: registry.community.greenbone.net/community/dfn-cert-data
volumes:
- cert_data_vol:/mnt
depends_on:
- cert-bund-data
data-objects:
- image: greenbone/data-objects
+ image: registry.community.greenbone.net/community/data-objects
volumes:
- data_objects_vol:/mnt
report-formats:
- image: greenbone/report-formats
+ image: registry.community.greenbone.net/community/report-formats
volumes:
- data_objects_vol:/mnt
depends_on:
- data-objects
gpg-data:
- image: greenbone/gpg-data
+ image: registry.community.greenbone.net/community/gpg-data
volumes:
- gpg_data_vol:/mnt
redis-server:
- image: greenbone/redis-server
+ image: registry.community.greenbone.net/community/redis-server
restart: on-failure
volumes:
- redis_socket_vol:/run/redis/
pg-gvm:
- image: greenbone/pg-gvm:stable
+ image: registry.community.greenbone.net/community/pg-gvm:stable
restart: on-failure
volumes:
- psql_data_vol:/var/lib/postgresql
- psql_socket_vol:/var/run/postgresql
gvmd:
- image: greenbone/gvmd:stable
+ image: registry.community.greenbone.net/community/gvmd:stable
restart: on-failure
volumes:
- gvmd_data_vol:/var/lib/gvm
@@ -86,7 +86,7 @@ services:
condition: service_completed_successfully
gsa:
- image: greenbone/gsa:stable
+ image: registry.community.greenbone.net/community/gsa:stable
restart: on-failure
ports:
- 127.0.0.1:9392:80
@@ -94,9 +94,73 @@ services:
- gvmd_socket_vol:/run/gvmd
depends_on:
- gvmd
+ # Sets log level of openvas to the set LOG_LEVEL within the env
+ # and changes log output to /var/log/openvas instead /var/log/gvm
+ # to reduce likelyhood of unwanted log interferences
+ configure-openvas:
+ image: registry.community.greenbone.net/community/openvas-scanner:stable
+ volumes:
+ - openvas_data_vol:/mnt
+ - openvas_log_data_vol:/var/log/openvas
+ command:
+ - /bin/sh
+ - -c
+ - |
+ printf "table_driven_lsc = yes\nopenvasd_server = http://openvasd:80\n" > /mnt/openvas.conf
+ sed "s/level=.*/level=INFO/" /etc/openvas/openvas_log.conf | sed 's/gvm/openvas/' > /mnt/openvas_log.conf
+ chmod 644 /mnt/openvas.conf
+ chmod 644 /mnt/openvas_log.conf
+ touch /var/log/openvas/openvas.log
+ chmod 666 /var/log/openvas/openvas.log
+
+ # shows logs of openvas
+ openvas:
+ image: registry.community.greenbone.net/community/openvas-scanner:stable
+ restart: on-failure
+ volumes:
+ - openvas_data_vol:/etc/openvas
+ - openvas_log_data_vol:/var/log/openvas
+ command:
+ - /bin/sh
+ - -c
+ - |
+ cat /etc/openvas/openvas.conf
+ tail -f /var/log/openvas/openvas.log
+ depends_on:
+ configure-openvas:
+ condition: service_completed_successfully
+
+ openvasd:
+ image: registry.community.greenbone.net/community/openvas-scanner:stable
+ restart: on-failure
+ environment:
+ # `service_notus` is set to disable everything but notus,
+ # if you want to utilize openvasd directly removed `OPENVASD_MODE`
+ OPENVASD_MODE: service_notus
+ GNUPGHOME: /etc/openvas/gnupg
+ LISTENING: 0.0.0.0:80
+ volumes:
+ - openvas_data_vol:/etc/openvas
+ - openvas_log_data_vol:/var/log/openvas
+ - gpg_data_vol:/etc/openvas/gnupg
+ - notus_data_vol:/var/lib/notus
+ # enable port forwarding when you want to use the http api from your host machine
+ # ports:
+ # - 127.0.0.1:3000:80
+ depends_on:
+ vulnerability-tests:
+ condition: service_completed_successfully
+ configure-openvas:
+ condition: service_completed_successfully
+ gpg-data:
+ condition: service_completed_successfully
+ networks:
+ default:
+ aliases:
+ - openvasd
ospd-openvas:
- image: greenbone/ospd-openvas:stable
+ image: registry.community.greenbone.net/community/ospd-openvas:stable
restart: on-failure
hostname: ospd-openvas.local
cap_add:
@@ -111,8 +175,6 @@ services:
"-f",
"--config",
"/etc/gvm/ospd-openvas.conf",
- "--mqtt-broker-address",
- "mqtt-broker",
"--notus-feed-dir",
"/var/lib/notus/advisories",
"-m",
@@ -124,6 +186,8 @@ services:
- notus_data_vol:/var/lib/notus
- ospd_openvas_socket_vol:/run/ospd
- redis_socket_vol:/run/redis/
+ - openvas_data_vol:/etc/openvas/
+ - openvas_log_data_vol:/var/log/openvas
depends_on:
redis-server:
condition: service_started
@@ -131,32 +195,11 @@ services:
condition: service_completed_successfully
vulnerability-tests:
condition: service_completed_successfully
-
- mqtt-broker:
- restart: on-failure
- image: greenbone/mqtt-broker
- networks:
- default:
- aliases:
- - mqtt-broker
- - broker
-
- notus-scanner:
- restart: on-failure
- image: greenbone/notus-scanner:stable
- volumes:
- - notus_data_vol:/var/lib/notus
- - gpg_data_vol:/etc/openvas/gnupg
- environment:
- NOTUS_SCANNER_MQTT_BROKER_ADDRESS: mqtt-broker
- NOTUS_SCANNER_PRODUCTS_DIRECTORY: /var/lib/notus/products
- depends_on:
- - mqtt-broker
- - gpg-data
- - vulnerability-tests
+ configure-openvas:
+ condition: service_completed_successfully
gvm-tools:
- image: greenbone/gvm-tools
+ image: registry.community.greenbone.net/community/gvm-tools
volumes:
- gvmd_socket_vol:/run/gvmd
- ospd_openvas_socket_vol:/run/ospd
@@ -177,3 +220,5 @@ volumes:
gvmd_socket_vol:
ospd_openvas_socket_vol:
redis_socket_vol:
+ openvas_data_vol:
+ openvas_log_data_vol: