-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile
45 lines (30 loc) · 1.03 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
41
42
43
44
45
FROM ubuntu:18.04
LABEL maintainer="Atomist <[email protected]>"
RUN apt-get update && apt-get install -y \
dumb-init \
&& rm -rf /var/lib/apt/lists/*
RUN mkdir -p /opt/app
WORKDIR /opt/app
EXPOSE 2866
ENV BLUEBIRD_WARNINGS 0
ENV NODE_ENV production
ENV NPM_CONFIG_LOGLEVEL warn
ENV SUPPRESS_NO_CONFIG_WARNING true
ENTRYPOINT ["dumb-init", "node", "--trace-warnings", "--expose_gc", "--optimize_for_size", "--always_compact", "--max_old_space_size=384"]
CMD ["/opt/app/node_modules/.bin/atm-start"]
RUN apt-get update && apt-get install -y \
build-essential \
curl \
git \
&& rm -rf /var/lib/apt/lists/*
RUN git config --global user.email "[email protected]" \
&& git config --global user.name "Atomist Bot"
RUN curl -sL https://deb.nodesource.com/setup_11.x | bash - \
&& apt-get install -y nodejs \
&& rm -rf /var/lib/apt/lists/*
COPY package.json package-lock.json ./
RUN npm ci \
&& npm cache clean --force
COPY . .
# Remove before running in production
ENV ATOMIST_ENV development