Explorar o código

fix again for docker

Lukas Goldschmidt hai 3 semanas
pai
achega
fd14a37292
Modificáronse 3 ficheiros con 4 adicións e 1 borrados
  1. 1 0
      Dockerfile
  2. 1 1
      README.md
  3. 2 0
      docker-compose.yml

+ 1 - 0
Dockerfile

@@ -1,5 +1,6 @@
 FROM python:3.13-slim
 FROM python:3.13-slim
 WORKDIR /app
 WORKDIR /app
+ENV METALS_HOST=0.0.0.0 METALS_RELOAD=0
 COPY requirements.txt ./
 COPY requirements.txt ./
 RUN pip install --no-cache-dir -r requirements.txt
 RUN pip install --no-cache-dir -r requirements.txt
 COPY . .
 COPY . .

+ 1 - 1
README.md

@@ -25,7 +25,7 @@ Default URL base: `http://127.0.0.1:8515`
 docker compose up -d --build
 docker compose up -d --build
 ```
 ```
 
 
-The compose file persists `data/` and `logs/` into the project directory and keeps the candle DB bounded.
+The compose file persists `data/` and `logs/` into the project directory, binds the server to `0.0.0.0`, and keeps the candle DB bounded.
 Reload is off by default in container runs, so the poller won't trigger watcher loops.
 Reload is off by default in container runs, so the poller won't trigger watcher loops.
 
 
 ## HTTP
 ## HTTP

+ 2 - 0
docker-compose.yml

@@ -1,10 +1,12 @@
 services:
 services:
   metals-mcp:
   metals-mcp:
     build: .
     build: .
+    container_name: metals-mcp
     restart: unless-stopped
     restart: unless-stopped
     ports:
     ports:
       - "8515:8515"
       - "8515:8515"
     environment:
     environment:
+      - METALS_HOST=0.0.0.0
       - METALS_PORT=8515
       - METALS_PORT=8515
       - METALS_RELOAD=0
       - METALS_RELOAD=0
       - METALS_DATA_DIR=/app/data
       - METALS_DATA_DIR=/app/data