18 lines
729 B
Plaintext
18 lines
729 B
Plaintext
|
FROM ubuntu:20.04 as binaries
|
||
|
RUN apt update && apt install -y curl gnupg2 ca-certificates
|
||
|
RUN curl -fsSL https://download.docker.com/linux/ubuntu/gpg | apt-key add -
|
||
|
RUN echo 'deb [arch=amd64] https://download.docker.com/linux/ubuntu focal stable' >> /etc/apt/sources.list
|
||
|
RUN curl -L https://github.com/a8m/envsubst/releases/download/v1.2.0/envsubst-`uname -s`-`uname -m` -o /usr/bin/envsubst
|
||
|
RUN chmod +x /usr/bin/envsubst
|
||
|
RUN apt update && apt install -y docker-ce-cli && apt clean all
|
||
|
|
||
|
FROM node:14 as modules
|
||
|
COPY --from=binaries /usr/bin/docker /usr/bin/docker
|
||
|
COPY --from=binaries /usr/bin/envsubst /usr/bin/envsubst
|
||
|
WORKDIR /usr/src/app
|
||
|
COPY ./package*.json .
|
||
|
RUN yarn install
|
||
|
|
||
|
FROM modules
|
||
|
WORKDIR /usr/src/app
|
||
|
COPY . .
|