Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion pmoves/services/cast-tts-gateway/auth.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,15 @@
with optional development mode bypass for local testing.
"""

import logging
import os
from typing import Callable, Awaitable

from aiohttp import web
import jose.jwt

logger = logging.getLogger(__name__)


async def get_user_context(request: web.Request) -> dict:
"""
Expand All @@ -34,9 +37,10 @@ async def get_user_context(request: web.Request) -> dict:

# Allow unauthenticated requests in development mode
if os.getenv("CAST_AUTH_REQUIRED", "true") == "false":
logger.warning("SECURITY: CAST_AUTH_REQUIRED=false — authentication bypassed (dev mode)")
return {
"user_id": "dev_user",
"role": "admin",
"role": "dev",
"email": "dev@pmoves.ai"
}

Expand Down
2 changes: 1 addition & 1 deletion pmoves/services/consciousness-service/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ USER pmoves
ENV SERVICE_NAME=consciousness-service
ENV SERVICE_PORT=8105
ENV NATS_URL=nats://nats:pmoves@nats:4222
ENV CHIT_PROD_PASSPHRASE=pmoves-chit-default
# CHIT_PROD_PASSPHRASE injected at runtime via docker-compose
ENV SUPABASE_URL=http://supabase-kong:8000
ENV PYTHONUNBUFFERED=1

Expand Down
4 changes: 3 additions & 1 deletion pmoves/services/consciousness-service/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,9 @@
SERVICE_NAME = os.environ.get("SERVICE_NAME", "consciousness-service")
SERVICE_PORT = int(os.environ.get("SERVICE_PORT", "8105"))
NATS_URL = os.environ.get("NATS_URL", "nats://nats:pmoves@nats:4222")
CHIT_PASSPHRASE = os.environ.get("CHIT_PROD_PASSPHRASE", "pmoves-chit-default")
CHIT_PASSPHRASE = os.environ.get("CHIT_PROD_PASSPHRASE", "")
if not CHIT_PASSPHRASE:
logger.warning("CHIT_PROD_PASSPHRASE not set — CGP signing disabled")
SUPABASE_URL = os.environ.get("SUPABASE_URL", "http://supabase-kong:8000")
SUPABASE_ANON_KEY = os.environ.get("SUPABASE_ANON_KEY", "")

Expand Down
1 change: 1 addition & 0 deletions pmoves/services/flute-gateway/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ def _build_nats_url() -> str:
return f"nats://{user}:{password}@{host}:{port}"
if user:
return f"nats://{user}@{host}:{port}"
logger.warning("NATS connection without credentials — set NATS_URL or NATS_USER/NATS_PASSWORD")
return f"nats://{host}:{port}"


Expand Down
1 change: 0 additions & 1 deletion pmoves/ui/app/api/audit/summary/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -350,7 +350,6 @@ export async function GET(request: NextRequest) {
return NextResponse.json(
{
generatedAt: new Date().toISOString(),
docsRoot,
warnings,
productionAudit: {
source: dashboardMarkdown ? dashboardPath : null,
Expand Down
Loading