Skip to content

Commit cc8c266

Browse files
committed
Allow for read-only container run
* Requires adding tmpfs for writable paths * uv run with --no-sync and --no-cache for read-only FS * Docker compose updated for read-only mode matching expected k8s usage
1 parent fc09ed4 commit cc8c266

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,4 +38,4 @@ RUN uv sync --frozen
3838

3939
EXPOSE 10011
4040

41-
ENTRYPOINT ["uv", "run", "uvicorn", "--host", "0.0.0.0", "--port", "10011", "--factory", "lexmachina_agent.server:app"]
41+
ENTRYPOINT ["uv", "run", "--no-sync", "--no-cache", "uvicorn", "--host", "0.0.0.0", "--port", "10011", "--factory", "lexmachina_agent.server:app"]

docker-compose.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ services:
1313
env_file:
1414
- .env # Optional: load environment variables from .env file
1515
restart: unless-stopped
16+
read_only: true
17+
tmpfs:
18+
- /tmp
1619
healthcheck:
1720
test: ["CMD", "curl", "-f", "http://localhost:10011/.well-known/agent-card.json"]
1821
interval: 30s

0 commit comments

Comments
 (0)