TensorGuy01 commited on
Commit
3dcea1c
·
verified ·
1 Parent(s): 4021684

Update Dockerfile

Browse files
Files changed (1) hide show
  1. Dockerfile +15 -3
Dockerfile CHANGED
@@ -1,5 +1,17 @@
1
- FROM python:3.10
 
2
 
3
- RUN apt update && apt install -y speedtest-cli
 
4
 
5
- CMD ["speedtest-cli", "--no-download"]
 
 
 
 
 
 
 
 
 
 
 
1
+ # Use a slim official Python base image
2
+ FROM python:3.10-slim
3
 
4
+ # Install required system packages (optional: for time zone or curl debugging)
5
+ RUN apt-get update && apt-get install -y curl && rm -rf /var/lib/apt/lists/*
6
 
7
+ # Install Python dependencies
8
+ RUN pip install --no-cache-dir requests
9
+
10
+ # Copy the speed test script into the container
11
+ COPY speedtest.py /app/speedtest.py
12
+
13
+ # Set working directory
14
+ WORKDIR /app
15
+
16
+ # Run the script on container start
17
+ CMD ["python", "speedtest.py"]