Hermes Agent 4a25b35667
Build & Deploy / build-and-deploy (push) Failing after 35s
fix: memory bloat from unlimited JVM heap and missing HTTP Range support
Two root causes for memory growing to 1.7GB and never shrinking:

1. No -Xmx limit (Dockerfile): JVM grew its heap without bound after
   processing large uploads and never returned memory to the OS. Now capped
   at 128MB with G1GC periodic GC every 30s to shrink when idle.

2. Broken HTTP Range (StaticResource): The server advertised
   Accept-Ranges: bytes but didn't actually handle Range headers —
   every request sent the entire .jsdos file (up to 1.2GB for GTA).
   The OS cached the full file in page cache, which counts against
   Docker container memory and persists after play stops.

   js-dos v7 loads .jsdos via Range requests (lazy ZIP loading).
   Now properly parses Range: bytes=start-end headers, responds with
   206 Partial Content, and seeks to exact offsets in the file —
   only the requested bytes stream through, keeping page cache minimal.
2026-06-03 15:38:22 +02:00
2026-05-28 23:14:35 +02:00

Dostalgia

A nostalgic DOS game hub. Upload your old DOS games, scrape artwork, and play them directly in the browser via js-dos (WebAssembly DOSBox).

Quick Start

# Build and run with Docker
docker build -t dostalgia .
docker run -p 8765:8765 -v $(pwd)/data:/data dostalgia

Open http://localhost:8765

Development (without Docker)

Terminal 1 — Frontend dev server:

cd frontend && npm install && npm run dev

Terminal 2 — Quarkus dev server:

mvn quarkus:dev

Open http://localhost:5173 (Vite proxies API calls to Quarkus on port 8765)

Production build (local)

cd frontend && npm install && npm run build
mvn package -DskipTests
java -jar target/quarkus-app/quarkus-run.jar

Architecture

  • Backend: Quarkus (Java 21, JAX-RS) — ~5 REST resource classes, zero database
  • Frontend: Svelte 5 SPA with hash-based routing
  • Emulation: js-dos v8 loaded from CDN, runs DOSBox in WebAssembly
  • Storage: JSON-per-game under /data/games/{id}/game.json

API

Method Path Description
GET /api/games List all games
GET /api/games/:id Get game details
PATCH /api/games/:id Update game metadata
DELETE /api/games/:id Delete a game
POST /api/upload Upload a game ZIP (multipart)
POST /api/games/:id/cover Upload cover art
GET /api/igdb/search?q= Search IGDB (placeholder)

Game JSON Schema

{
  "id": "doom",
  "title": "Doom",
  "year": 1993,
  "genre": "FPS",
  "developer": "id Software",
  "bundle_file": "doom.jsdos",
  "has_cover": true,
  "ready": true
}
S
Description
A nostalgic DOS game hub — upload, scrape artwork, and play your classic games in the browser
Readme MIT 5.6 MiB
Languages
Java 62.2%
Svelte 24.7%
JavaScript 8.8%
CSS 3.4%
Dockerfile 0.5%
Other 0.4%