web: dynamic ports redirect errors
Local Docker Build (Dev) / build-dev (push) Successful in 4s

This commit is contained in:
2025-10-22 12:20:52 -04:00
parent 6f5341cbc6
commit 9b03fb50ea
2 changed files with 7 additions and 1 deletions
+6 -1
View File
@@ -1872,10 +1872,15 @@ def register_routes(app, dependencies: dict):
@app.get("/") @app.get("/")
async def _core_info(): async def _core_info():
"""Core container API information - Web interface on separate container""" """Core container API information - Web interface on separate container"""
import os
# Get configured web port from environment or config
web_port = os.environ.get("WEB_EXTERNAL_PORT",
getattr(dependencies.get("config", None), "web_api_port", "8081"))
return { return {
"service": "NFOGuard Core Processing Engine", "service": "NFOGuard Core Processing Engine",
"version": "2.7.0", "version": "2.7.0",
"message": "Web interface available on separate container (port 8081)", "message": f"Web interface available on separate container (port {web_port})",
"api_endpoints": { "api_endpoints": {
"health": "/health", "health": "/health",
"webhooks": "/webhook/*", "webhooks": "/webhook/*",
+1
View File
@@ -45,6 +45,7 @@ services:
- TZ=${TZ:-America/New_York} - TZ=${TZ:-America/New_York}
- CORE_API_HOST=0.0.0.0 - CORE_API_HOST=0.0.0.0
- CORE_API_PORT=8080 - CORE_API_PORT=8080
- WEB_EXTERNAL_PORT=${WEB_API_PORT:-8081} # External port where web interface is accessible
volumes: volumes:
# Media paths (adjust to your setup) # Media paths (adjust to your setup)
- /mnt/unionfs/Media/TV:/media/TV:ro - /mnt/unionfs/Media/TV:/media/TV:ro