forked from eliagonzalezmolina/google-maps-reviews-scraper
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathDockerfile
40 lines (30 loc) · 1.19 KB
/
Dockerfile
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 python:3.12-slim
WORKDIR /app
RUN pip install poetry
RUN apt-get update && apt-get install -y make
# Install Node.js, npm
RUN apt-get update && apt-get install -y curl
RUN curl -fsSL https://deb.nodesource.com/setup_16.x | bash -
RUN apt-get install -y nodejs
ENV CHROMEDRIVER_VERSION=124.0.6367.60
# Install chrome
RUN apt-get update && apt-get install -y wget && apt-get install -y zip
RUN wget -q https://dl.google.com/linux/direct/google-chrome-stable_current_amd64.deb
RUN apt-get install -y ./google-chrome-stable_current_amd64.deb
# Install chromedriver
RUN wget https://storage.googleapis.com/chrome-for-testing-public/$CHROMEDRIVER_VERSION/linux64/chromedriver-linux64.zip \
&& unzip chromedriver-linux64.zip && rm -dfr chromedriver_linux64.zip \
&& mv ./chromedriver-linux64/chromedriver /usr/local/share/chromedriver \
&& ln -s /usr/local/share/chromedriver /usr/local/bin/chromedriver \
&& ln -s /usr/local/share/chromedriver /usr/bin/chromedriver \
&& chmod +x /usr/bin/chromedriver
ENV PATH /usr/bin/chromedriver:$PATH
ENV GOOGLE_APPLICATION_CREDENTIALS=/app/crawler_gcp_keyfile.json
COPY . /app
RUN make install
# # Clean
# RUN make clean
# # RUN
# RUN make run
# Bash
CMD ["bash"]