PunchNFIT commited on
Commit
94c33ad
·
1 Parent(s): dcd1f39

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +11 -12
Dockerfile CHANGED
@@ -1,21 +1,20 @@
1
- # Use lightweight Python base image
2
  FROM python:3.10-slim
3
 
4
- # Set working directory
5
  WORKDIR /app
6
 
7
- # Copy all local files into container
8
- COPY . .
9
-
10
- # Ensure custom architecture file is available
11
- COPY ./snp_universal_embedding.py /app/snp_universal_embedding.py
 
 
12
 
13
  # Install dependencies
14
- RUN pip install --no-cache-dir torch transformers flask sentence-transformers
15
-
16
- # Expose Cloud Run port
17
- ENV PORT=8080
18
 
19
- # Run the API
20
  EXPOSE 7860
 
 
21
  CMD ["python", "api_inference.py"]
 
 
1
  FROM python:3.10-slim
2
 
 
3
  WORKDIR /app
4
 
5
+ # Explicitly copy each required file
6
+ COPY api_inference.py /app/api_inference.py
7
+ COPY snp_universal_embedding.py /app/snp_universal_embedding.py
8
+ COPY config.json /app/config.json
9
+ COPY tokenizer.json /app/tokenizer.json
10
+ COPY pytorch_model.bin /app/pytorch_model.bin
11
+ COPY requirements.txt /app/requirements.txt
12
 
13
  # Install dependencies
14
+ RUN pip install --no-cache-dir -r requirements.txt
 
 
 
15
 
16
+ # Expose Hugging Face port
17
  EXPOSE 7860
18
+
19
+ # Start the Flask app
20
  CMD ["python", "api_inference.py"]