-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathDockerfile
More file actions
40 lines (30 loc) · 1.35 KB
/
Dockerfile
File metadata and controls
40 lines (30 loc) · 1.35 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
31
32
33
34
35
36
37
38
39
40
FROM --platform=linux/amd64 python:3.8
RUN ["apt-get", "-y", "update"]
RUN ["apt", "install", "-y", "wget", "gnupg", "curl"]
# Fetch google chrome
RUN wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add -
RUN sh -c 'echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable main" >> /etc/apt/sources.list.d/google.list'
RUN ["apt-get", "-y", "update"]
RUN ["apt-get", "-y", "upgrade"]
RUN ["apt-get", "install", "-y", "google-chrome-stable"]
# Download chromedriver
RUN wget -O /tmp/chromedriver.zip http://chromedriver.storage.googleapis.com/`curl -sS chromedriver.storage.googleapis.com/LATEST_RELEASE`/chromedriver_linux64.zip
RUN apt-get install -yqq unzip
RUN unzip /tmp/chromedriver.zip chromedriver -d /usr/local/bin/
RUN chmod +x /usr/local/bin/chromedriver
ENV DISPLAY=:99
COPY . /deliveroo-webscraping-team
WORKDIR /deliveroo-webscraping-team
ENV DB_HOST="del_db"
ENV DB_USER="del"
ENV DB_PASSWORD="ahj%ZF2*TIZk"
ENV DB_NAME="postgresdb"
ENV DB_PORT=5432
ENV SENTRY_DSN="https://d2744aa667304febbb8766ca55f650f8@o1086610.ingest.sentry.io/6098931"
ENV SENTRY_ENVIRONMENT="dev"
# Setup boto3
ENV AWS_ACCESS_KEY_ID="AKIAZMXVD3RWL6EKMB56"
ENV AWS_SECRET_ACCESS_KEY="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"
ENV REGION_NAME="eu-west-2"
RUN ["pip3", "install", "-r", "requirements.txt"]
ENTRYPOINT [ "python3.8", "main.py" ]