-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
30 lines (22 loc) · 1.08 KB
/
Dockerfile
File metadata and controls
30 lines (22 loc) · 1.08 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
FROM --platform=linux/amd64 python:3.11-slim
# Install dependencies required for adding a new repository
RUN apt-get update && apt-get install -y wget gnupg2
# Adding Google Chrome (for selenium) and Tesseract for OCR. Git for using github
RUN wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add - && \
sh -c 'echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google-chrome.list' && \
apt-get update && apt-get install -y \
git \
google-chrome-stable \
# Add additional packages here, before the cleanup line
&& rm -rf /var/lib/apt/lists/* # Clean up to keep the image size down
# Set the working directory in the container
WORKDIR /app
# Copy the requirements file into the container
COPY requirements.txt .
# Install Python dependencies
RUN pip install --no-cache-dir -r requirements.txt
# Set the PYTHONPATH environment variable so we can import modules from the app
ENV PYTHONPATH=/app
# Copy the current directory contents into the container
COPY . .
ENTRYPOINT ["python", "watchdog.py"]