Commit graph

22 commits

Author SHA1 Message Date
Lazzexus
9bdb6a5812 Make browsers check for a new web map on every load
main.bundle.js and the CSS keep the same name in every version, and nginx
didn't send Cache-Control, so browsers could keep running the old bundle
after a deploy. Then new pages (like /research/tree) showed the landing
page, stuck on "Loading servers…".

Send Cache-Control: no-cache, so browsers revalidate each load; unchanged
files are still a cheap 304 via the ETag. Icons keep their 1 day expiry.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-22 10:26:40 +01:00
Lazzexus
c773b05922 Add a building icon layer to the web map
events-server-web keeps the latest state of every building in memory (read
from the map-chunk-entity topic, like the resource patches) and serves them
per area. The web map draws the icons at their real size onto canvas tiles,
so large bases stay fast, and shows each building's name, status and health
on hover. Ghosts are ignored, and buildings are removed when they're mined.

The icons belong to Wube and the mod authors, so they aren't in the repo.
export_building_icons.py builds them from a Factorio client's
--dump-data/--dump-prototype-locale/--dump-icon-sprites output, and the
web-map nginx serves them from a mounted volume.

Also label single-well oil fields "1 well".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-21 09:52:07 +02:00
Lazzexus
e52ea9d9cf Fix Docker image builds and local platform setup
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>
2026-10-12 17:27:11 +02:00
Adam
9b331cc105 update dockerfiles
- define user uid/gid
- use new geedeecee files (hopefully means smaller images, faster building)
2022-10-22 19:55:02 +02:00
Adam
32b4bbffe2 maybe fix webmap nginx css... 2022-10-08 16:05:44 +02:00
Adam
59dc4ce336 add nginx events section 2022-10-08 14:52:40 +02:00
Adam
562296aa96 Dockerfiles: add syntax=docker header 2022-10-04 22:28:04 +02:00
Adam
0044f0cb98 create and use APP_NAME, APP_GROUP in docker compose files 2022-10-04 22:27:43 +02:00
Adam
99d1f92bbb update docker image names to include REGISTRY_HOST, and group, and correct image name 2022-10-02 14:51:00 +02:00
Adam
9071148944 start dockerising the modules... 2022-09-18 23:38:15 +02:00
Adam
a84c4a2f76 refactor web-map to be SPA 2022-09-09 17:21:09 +02:00
Adam
02edffa2e9 version bump to 0.9.0 (just prepping for the next release) 2022-09-01 23:17:56 +02:00
Adam
10c54998c7 version bump to 0.8.0 2022-07-16 23:23:55 +02:00
Adam
ae0eb98f12 version bump 2022-07-08 21:48:19 +02:00
Adam
665327e010 bump project to 0.7.0 (and fix docker .env task for all docker .envs) 2022-07-06 17:43:50 +02:00
Adam Semenenko
5ac50e8412 Merge branch 'main' of github.com:adamko-dev/kafkatorio 2022-06-27 22:04:05 +01:00
Adam Semenenko
866c3e5c8f add restart-unless-stopped to containers 2022-06-27 22:04:01 +01:00
Adam
e078e6316d manually bump Kafkatorio versions for events-server and web-map (I still need to automate that...) 2022-06-26 23:50:30 +02:00
Adam Semenenko
cf5804b42d get traefik working 2022-06-25 13:42:50 +01:00
Adam
7b78f117fd bump Kafkatorio version in .env files (still need to make this automatic...) 2022-06-24 14:54:20 +02:00
Adam Semenenko
82c8b9f25b add traefik nw to docker files 2022-06-23 23:00:42 +01:00
Adam
b56c0df824 start getting docker images working... 2022-06-21 00:00:26 +02:00