-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile
27 lines (20 loc) · 826 Bytes
/
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
# docker build --rm=false -t idangozlan/rendertron .
# This Docker image will install and run latest rendertron
FROM node:lts-alpine
# Installs latest Chromium (85) package.
RUN apk add --no-cache \
chromium \
nss \
nodejs
# We let puppeteer skip chromium download, since Alpine built a little bit different than other dists
ENV PUPPETEER_SKIP_CHROMIUM_DOWNLOAD=true \
PUPPETEER_EXECUTABLE_PATH=/usr/bin/chromium-browser
# Creating working directory for our run.sh file (which runs the rendertron update + launch)
RUN mkdir -p /usr/src/app
WORKDIR /usr/src/app
COPY run.sh /usr/src/app
# Adding current latest of rendertron to save some time when docker start running (installation + run)
# unsafe flag is for permission fixing
RUN npm i -g rendertron --unsafe
EXPOSE 3000
CMD /usr/src/app/run.sh