File size: 458 Bytes
fecbfc9
 
d2ae842
fecbfc9
 
 
 
 
 
d2ae842
 
 
 
 
 
 
fecbfc9
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# Use the official image. The engine is already installed here.
FROM ghcr.io/abetlen/llama-cpp-python:latest

# Switch to root to install Gradio
USER root
RUN python3 -m pip install --upgrade pip
RUN python3 -m pip install gradio huggingface_hub

# Setup User (Required by Hugging Face)
RUN useradd -m -u 1000 user
USER user
ENV HOME=/home/user \
    PATH=/home/user/.local/bin:$PATH
WORKDIR $HOME/app
COPY --chown=user . $HOME/app

CMD ["python3", "app.py"]