2022-02-14 09:35:55 +01:00
|
|
|
|
2023-08-15 14:00:25 +02:00
|
|
|
FROM ubuntu:20.04 as base
|
|
|
|
RUN apt-get update && apt-get -y install bash curl
|
|
|
|
RUN curl -sL https://deb.nodesource.com/setup_16.x -o /tmp/nodesource_setup.sh
|
|
|
|
RUN bash /tmp/nodesource_setup.sh
|
|
|
|
RUN apt install nodejs
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
FROM base as builder
|
|
|
|
RUN apt-get update && apt-get -y install wget
|
2022-02-14 09:35:55 +01:00
|
|
|
COPY package*.json /usr/src/app/
|
2023-08-15 14:00:25 +02:00
|
|
|
WORKDIR /usr/src/app/
|
|
|
|
ENV NODE_ENV=production
|
|
|
|
RUN npm ci
|
|
|
|
|
2022-02-14 09:35:55 +01:00
|
|
|
|
2023-08-15 14:00:25 +02:00
|
|
|
FROM base as runner
|
|
|
|
ENV NODE_ENV=production
|
2022-02-14 09:35:55 +01:00
|
|
|
COPY . /usr/src/app
|
2023-08-15 14:00:25 +02:00
|
|
|
WORKDIR /usr/src/app/
|
|
|
|
COPY --from=builder /usr/src/app/node_modules/ /usr/src/app/node_modules/
|
2022-02-14 09:35:55 +01:00
|
|
|
ENV DEPLOY_SUBGRAPH=true
|
|
|
|
ENTRYPOINT ["/usr/src/app/docker-entrypoint.sh"]
|