File size: 325 Bytes
f48b421
 
bc65857
 
569958e
bc65857
ba00a28
 
 
 
1b4a88d
bc65857
1
2
3
4
5
6
7
8
9
10
11
12
13
FROM ghcr.io/huggingface/text-generation-inference:latest

# Define a pre-existing Hugging Face model
ENV MODEL_ID="gpt2"

# Use a writable cache directory
ENV HF_HOME="/tmp"
ENV TRANSFORMERS_CACHE="/tmp"
ENV HUGGINGFACE_HUB_CACHE="/tmp"

# Run the TGI server
CMD ["--model-id", "gpt2", "--port", "8080", "--num-shard", "1"]