Add Presidio detector Dockerfile

This commit is contained in:
2026-07-01 04:54:57 +00:00
parent 1be1170af4
commit eba1867888

19
presidio/Dockerfile Normal file
View File

@@ -0,0 +1,19 @@
FROM python:3.12-slim
WORKDIR /app
RUN pip install --no-cache-dir \
presidio-analyzer \
"spacy>=3.7" \
fastapi \
uvicorn \
pydantic
# Traditional/Simplified Chinese model for PERSON detection.
# For stronger zh-TW name recall you would swap/augment this in a real engagement.
RUN python -m spacy download zh_core_web_lg
COPY app.py .
EXPOSE 5001
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "5001"]