fix automated docker builds

This commit is contained in:
Amruth Pillai
2020-04-02 17:32:13 +05:30
parent 3eb90dbc61
commit 3b0f0adfda
2 changed files with 8 additions and 2 deletions

View File

@ -1,5 +1,5 @@
## build image ## build image
FROM node:13.12.0-buster-slim as build FROM node:13.12.0-alpine as build
## set working directory ## set working directory
WORKDIR /usr/src/app WORKDIR /usr/src/app
@ -10,6 +10,9 @@ ENV PATH /usr/src/app/node_modules/.bin:$PATH
## install and cache app dependencies ## install and cache app dependencies
COPY package.json /usr/src/app/package.json COPY package.json /usr/src/app/package.json
## install git
RUN apk add --no-cache git
## install app dependencies ## install app dependencies
RUN npm install RUN npm install

View File

@ -1,5 +1,5 @@
## base image ## base image
FROM node:13.12.0-buster-slim FROM node:13.12.0-alpine
## set working directory ## set working directory
WORKDIR /usr/src/app WORKDIR /usr/src/app
@ -10,6 +10,9 @@ ENV PATH /usr/src/app/node_modules/.bin:$PATH
## install and cache app dependencies ## install and cache app dependencies
COPY package.json /usr/src/app/package.json COPY package.json /usr/src/app/package.json
## install git
RUN apk add --no-cache git
## install app dependencies ## install app dependencies
RUN npm install RUN npm install