Skip to content

Instantly share code, notes, and snippets.

@webseo-onilne
Created July 16, 2018 09:32
Show Gist options
  • Save webseo-onilne/bf7eaa5d49ba398c18a73cc54f61f251 to your computer and use it in GitHub Desktop.
Save webseo-onilne/bf7eaa5d49ba398c18a73cc54f61f251 to your computer and use it in GitHub Desktop.
# For angular app
FROM nginx:alpine
COPY mgt-dash/nginx.conf /etc/nginx/nginx.conf
WORKDIR /usr/share/nginx/html
COPY mgt-dash/dist/mtg-dash .
# For node express server
FROM node:8
# Create app directory
WORKDIR /usr/src/app/release
# Install app dependencies
# A wildcard is used to ensure both package.json AND package-lock.json are copied
# where available (npm@5+)
COPY server/package*.json ./
RUN npm install
# If you are building your code for production
# RUN npm install --only=production
# Bundle app source
COPY . .
EXPOSE 4000
CMD [ "npm", "start" ]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment