From 7e9e1b0ccaeb57d871a948abd0aac448a72bae37 Mon Sep 17 00:00:00 2001 From: ekneg54 Date: Tue, 11 Jun 2024 09:06:05 +0200 Subject: [PATCH 1/3] add ipam configs for networks --- quickstart/docker-compose.yml | 40 ++++++++++++++++++++++++++++------- 1 file changed, 32 insertions(+), 8 deletions(-) diff --git a/quickstart/docker-compose.yml b/quickstart/docker-compose.yml index e9201da7b..8302da888 100644 --- a/quickstart/docker-compose.yml +++ b/quickstart/docker-compose.yml @@ -66,14 +66,14 @@ services: test: [ "CMD-SHELL", - "kafka-topics.sh --bootstrap-server 127.0.0.1:9092 --topic consumer --describe" + "kafka-topics.sh --bootstrap-server 127.0.0.1:9092 --topic consumer --describe", ] networks: - kafka kafka-exporter: image: bitnami/kafka-exporter container_name: kafkaexporter - command: [ "--kafka.server=kafka:9092" ] + command: ["--kafka.server=kafka:9092"] ports: - "9308:9308" depends_on: @@ -101,7 +101,7 @@ services: volumes: - ../quickstart/:/home/logprep/quickstart/ tmpfs: - - /tmp/logprep/prometheus_multiproc + - /tmp/logprep/prometheus_multiproc entrypoint: - logprep - run @@ -281,9 +281,9 @@ services: WEB_CONCURRENCY: 4 SECURE_SSL_REDIRECT: "False" UCL_BASE_URL: http://localhost:8000/api/v1 - DJANGO_SECRET_KEY: 'django-insecure-secret_key' + DJANGO_SECRET_KEY: "django-insecure-secret_key" ALLOWED_HOSTS: "*" - CORS_ALLOWED_ORIGINS: http://localhost # neccessary if CORS_ORIGIN_ALLOW_ALL=FALSE + CORS_ALLOWED_ORIGINS: http://localhost # neccessary if CORS_ORIGIN_ALLOW_ALL=FALSE CORS_ORIGIN_ALLOW_ALL: "True" DJANGO_DEBUG: "True" KEYCLOAK_SERVER_URL: http://keycloak:8080 @@ -298,7 +298,7 @@ services: ucl-db: condition: service_healthy entrypoint: - - ./docker/docker-entrypoint.sh + - ./docker/docker-entrypoint.sh security_opt: - no-new-privileges:true tmpfs: @@ -308,7 +308,7 @@ services: - keycloak ucl-db: container_name: ucl-db - image: 'postgres:14' + image: "postgres:14" read_only: true volumes: - ucl-db-volume:/var/lib/postgresql/data @@ -317,7 +317,7 @@ services: POSTGRES_PASSWORD: ucl POSTGRES_DB: ucl healthcheck: - test: 'pg_isready --username=$$POSTGRES_USER && psql --username=$$POSTGRES_USER --list' + test: "pg_isready --username=$$POSTGRES_USER && psql --username=$$POSTGRES_USER --list" interval: 8s timeout: 5s retries: 10 @@ -351,8 +351,32 @@ volumes: networks: opensearch: + ipam: + config: + - subnet: 192.168.223.0/29 + gateway: 192.168.223.1 fda: + ipam: + config: + - subnet: 192.168.223.8/29 + gateway: 192.168.223.9 ucl: + ipam: + config: + - subnet: 192.168.223.16/29 + gateway: 192.168.223.17 keycloak: + ipam: + config: + - subnet: 192.168.223.24/29 + gateway: 192.168.223.25 kafka: + ipam: + config: + - subnet: 192.168.223.32/29 + gateway: 192.168.223.33 prometheus: + ipam: + config: + - subnet: 192.168.223.40/29 + gateway: 192.168.223.41 From 166b6b9cbf5f4fb84243a529e0ee373194130837 Mon Sep 17 00:00:00 2001 From: ekneg54 Date: Tue, 11 Jun 2024 09:54:35 +0200 Subject: [PATCH 2/3] add blank sample files grafana wants to create these on startup but can't write into mounted hosts filesystem. you get a permission denied. --- quickstart/exampledata/config/grafana/dashboards/sample.yaml | 0 quickstart/exampledata/config/grafana/datasources/sample.yaml | 0 2 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 quickstart/exampledata/config/grafana/dashboards/sample.yaml create mode 100644 quickstart/exampledata/config/grafana/datasources/sample.yaml diff --git a/quickstart/exampledata/config/grafana/dashboards/sample.yaml b/quickstart/exampledata/config/grafana/dashboards/sample.yaml new file mode 100644 index 000000000..e69de29bb diff --git a/quickstart/exampledata/config/grafana/datasources/sample.yaml b/quickstart/exampledata/config/grafana/datasources/sample.yaml new file mode 100644 index 000000000..e69de29bb From 0be29575506c8f1b7ca5db81c5673f83b937badb Mon Sep 17 00:00:00 2001 From: ekneg54 Date: Tue, 11 Jun 2024 09:56:05 +0200 Subject: [PATCH 3/3] update host entry --- quickstart/docker-compose.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/quickstart/docker-compose.yml b/quickstart/docker-compose.yml index 8302da888..199861d1e 100644 --- a/quickstart/docker-compose.yml +++ b/quickstart/docker-compose.yml @@ -128,7 +128,7 @@ services: - prometheus extra_hosts: # enables prometheus to access the host system (eg when logprep is running locally in the terminal) - - "host.docker.internal:172.17.0.1" + - "host.docker.internal:192.168.223.41" config: image: nginx:latest container_name: config