refactor: simplify Docker Compose configuration and add spacy dependency

- Changed server port binding from explicit `0.0.0.0:50051:50051` to `50051:50051` for standard Docker port mapping
- Commented out unused `server-full` and `client-dev` service definitions to reduce configuration complexity
- Added `spacy>=3.8.11` to project dependencies
This commit is contained in:
2026-01-03 02:28:58 -05:00
parent df0b30eaad
commit 95d1a98cc2
3 changed files with 58 additions and 55 deletions

View File

@@ -87,7 +87,7 @@ services:
target: server
restart: unless-stopped
ports:
- "0.0.0.0:50051:50051"
- "50051:50051"
extra_hosts:
- "host.docker.internal:host-gateway"
env_file:
@@ -113,62 +113,62 @@ services:
- server
- full
server-full:
container_name: noteflow-server-full
build:
context: .
dockerfile: docker/server.Dockerfile
target: server-full
restart: unless-stopped
ports:
- "50051:50051"
extra_hosts:
- "host.docker.internal:host-gateway"
env_file:
- .env
environment:
NOTEFLOW_DATABASE_URL: postgresql+asyncpg://${POSTGRES_USER:-noteflow}:${POSTGRES_PASSWORD:-noteflow}@db:5432/${POSTGRES_DB:-noteflow}
NOTEFLOW_REDIS_URL: redis://redis:6379/0
NOTEFLOW_QDRANT_URL: http://qdrant:6333
NOTEFLOW_LOG_FORMAT: console
volumes:
- .:/workspace
- server_venv:/workspace/.venv
depends_on:
db:
condition: service_healthy
redis:
condition: service_healthy
qdrant:
condition: service_healthy
networks:
- noteflow-net
profiles:
- server-full
# server-full:
# container_name: noteflow-server-full
# build:
# context: .
# dockerfile: docker/server.Dockerfile
# target: server-full
# restart: unless-stopped
# ports:
# - "50051:50051"
# extra_hosts:
# - "host.docker.internal:host-gateway"
# env_file:
# - .env
# environment:
# NOTEFLOW_DATABASE_URL: postgresql+asyncpg://${POSTGRES_USER:-noteflow}:${POSTGRES_PASSWORD:-noteflow}@db:5432/${POSTGRES_DB:-noteflow}
# NOTEFLOW_REDIS_URL: redis://redis:6379/0
# NOTEFLOW_QDRANT_URL: http://qdrant:6333
# NOTEFLOW_LOG_FORMAT: console
# volumes:
# - .:/workspace
# - server_venv:/workspace/.venv
# depends_on:
# db:
# condition: service_healthy
# redis:
# condition: service_healthy
# qdrant:
# condition: service_healthy
# networks:
# - noteflow-net
# profiles:
# - server-full
# Tauri client dev container (for CI/containerized development)
# Note: Desktop apps typically run natively, not in Docker
client-dev:
container_name: noteflow-client-dev
build:
context: .
dockerfile: docker/client.Dockerfile
target: client-dev
environment:
NOTEFLOW_SERVER_HOST: server
NOTEFLOW_SERVER_PORT: 50051
DISPLAY: ${DISPLAY:-:0}
volumes:
- ./client:/app/client
- /tmp/.X11-unix:/tmp/.X11-unix:ro
- client_cargo_cache:/root/.cargo/registry
- client_npm_cache:/root/.npm
depends_on:
- server
networks:
- noteflow-net
profiles:
- client
# client-dev:
# container_name: noteflow-client-dev
# build:
# context: .
# dockerfile: docker/client.Dockerfile
# target: client-dev
# environment:
# NOTEFLOW_SERVER_HOST: server
# NOTEFLOW_SERVER_PORT: 50051
# DISPLAY: ${DISPLAY:-:0}
# volumes:
# - ./client:/app/client
# - /tmp/.X11-unix:/tmp/.X11-unix:ro
# - client_cargo_cache:/root/.cargo/registry
# - client_npm_cache:/root/.npm
# depends_on:
# - server
# networks:
# - noteflow-net
# profiles:
# - client
frontend:
image: node:20-alpine

View File

@@ -32,6 +32,7 @@ dependencies = [
# Structured logging
"structlog>=24.0",
"sounddevice>=0.5.3",
"spacy>=3.8.11",
]
[project.optional-dependencies]

4
uv.lock generated
View File

@@ -1,5 +1,5 @@
version = 1
revision = 3
revision = 2
requires-python = ">=3.12"
resolution-markers = [
"python_full_version >= '3.13'",
@@ -2250,6 +2250,7 @@ dependencies = [
{ name = "pydantic-settings" },
{ name = "rich" },
{ name = "sounddevice" },
{ name = "spacy" },
{ name = "sqlalchemy", extra = ["asyncio"] },
{ name = "structlog" },
{ name = "types-psutil" },
@@ -2431,6 +2432,7 @@ requires-dist = [
{ name = "sounddevice", marker = "extra == 'audio'", specifier = ">=0.4.6" },
{ name = "sounddevice", marker = "extra == 'optional'", specifier = ">=0.4.6" },
{ name = "sourcery", marker = "sys_platform == 'darwin' and extra == 'dev'" },
{ name = "spacy", specifier = ">=3.8.11" },
{ name = "spacy", marker = "extra == 'ner'", specifier = ">=3.8.11" },
{ name = "spacy", marker = "extra == 'optional'", specifier = ">=3.8.11" },
{ name = "sqlalchemy", extras = ["asyncio"], specifier = ">=2.0" },