för att man inte kan ladda upp flerigen
This commit is contained in:
20
dockerfile
Normal file
20
dockerfile
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
FROM python:3.11-slim
|
||||||
|
|
||||||
|
# Install Chrome and dependencies
|
||||||
|
RUN apt-get update && \
|
||||||
|
apt-get install -y wget gnupg2 && \
|
||||||
|
wget -q -O - https://dl.google.com/linux/linux_signing_key.pub | apt-key add - && \
|
||||||
|
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 google-chrome-stable chromium-driver && \
|
||||||
|
apt-get clean
|
||||||
|
|
||||||
|
# Install Python dependencies
|
||||||
|
COPY requirements.txt .
|
||||||
|
RUN pip install --no-cache-dir -r requirements.txt
|
||||||
|
|
||||||
|
# Copy your crawler code
|
||||||
|
COPY . /app
|
||||||
|
WORKDIR /app
|
||||||
|
|
||||||
|
CMD ["python3", "crawler.py"]
|
||||||
Reference in New Issue
Block a user