Chipan commited on
Commit
4603db8
·
verified ·
1 Parent(s): 1328b46

Create Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +22 -0
Dockerfile ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Gunakan image Python resmi
2
+ FROM python:3.10-slim
3
+
4
+ # Install system dependencies
5
+ RUN apt-get update && apt-get install -y \
6
+ git \
7
+ && apt-get clean
8
+
9
+ # Buat working directory
10
+ WORKDIR /code
11
+
12
+ # Copy semua file ke image
13
+ COPY . .
14
+
15
+ # Install dependensi Python
16
+ RUN pip install --no-cache-dir -r requirements.txt
17
+
18
+ # Expose port default FastAPI
19
+ EXPOSE 7860
20
+
21
+ # Jalankan server FastAPI
22
+ CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "7860"]