Add local MarianMT translation service
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
FROM python:3.11-slim
|
||||
|
||||
WORKDIR /app
|
||||
COPY requirements.txt ./
|
||||
RUN pip install --no-cache-dir -r requirements.txt
|
||||
COPY server.py ./
|
||||
|
||||
ENV MARIAN_HOST=0.0.0.0
|
||||
ENV TRANSFORMERS_CACHE=/models
|
||||
VOLUME ["/models"]
|
||||
EXPOSE 8000
|
||||
|
||||
CMD ["python", "server.py"]
|
||||
Reference in New Issue
Block a user