Getting the backend running locally in Docker surfaced several issues: - geedeecee: REGISTRY_HOST came from the unset Gradle property 'dockerContainerRegistryHost'. A missing value in a MapProperty makes the whole map absent, so every generated .env was empty and all docker-compose builds failed. Default it to 'localhost'. - kafka image: dlcdn.apache.org only hosts current releases, so Kafka 3.3.1 404s. Use archive.apache.org. Replace the deprecated openjdk:11 base with eclipse-temurin:11-jre, bump the download stage from EOL Debian 11 to 12, and drop 'COPY --chmod' so the image builds without BuildKit/buildx. - web-map: the map calls the API and websocket on its own origin (/kafkatorio/...), which previously relied on an external reverse proxy. Proxy /kafkatorio/ to events-server-web in the map's nginx so one port serves everything, and publish that port in the example platform compose file. - docs: the example secret config mapped server IDs to descriptions, but the schema is token (JWT 'sub') -> server ID, and both must match [a-zA-Z0-9-_]. Descriptions with spaces crashed every service. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
41 lines
1.1 KiB
Nginx Configuration File
41 lines
1.1 KiB
Nginx Configuration File
events {}
|
|
|
|
http {
|
|
include mime.types;
|
|
default_type application/octet-stream;
|
|
|
|
# Sets the path, format, and configuration for a buffered log write
|
|
#log_format compression '$remote_addr - $remote_user [$time_local] '
|
|
#'"$request" $status $upstream_addr '
|
|
#'"$http_referer" "$http_user_agent"';
|
|
|
|
server {
|
|
listen 80;
|
|
|
|
root /usr/share/nginx/html;
|
|
|
|
index index.html;
|
|
|
|
# Docker's internal DNS - resolve the backend lazily, so nginx can start before it
|
|
resolver 127.0.0.11 valid=10s;
|
|
|
|
# proxy REST + WebSocket requests to events-server-web, so the map and the API share an origin
|
|
location /kafkatorio/ {
|
|
set $events_server_web http://events-server-web:80;
|
|
proxy_pass $events_server_web;
|
|
proxy_http_version 1.1;
|
|
proxy_set_header Upgrade $http_upgrade;
|
|
proxy_set_header Connection "upgrade";
|
|
proxy_set_header Host $host;
|
|
proxy_read_timeout 1h;
|
|
}
|
|
|
|
location / {
|
|
# First attempt to serve request as file, then
|
|
# as directory, then fall back to redirecting to index.html
|
|
try_files $uri $uri/ $uri.html /index.html;
|
|
|
|
include mime.types;
|
|
}
|
|
}
|
|
}
|