Skip to content

Instantly share code, notes, and snippets.

@ctrlaltdylan
Created February 24, 2020 15:37
Show Gist options
  • Save ctrlaltdylan/16db454c4f50226b2d1936c0a3ba963b to your computer and use it in GitHub Desktop.
Save ctrlaltdylan/16db454c4f50226b2d1936c0a3ba963b to your computer and use it in GitHub Desktop.
Angular Docker example
version: '3'
services:
app:
container_name: app
build:
context: ./app
dockerfile: dockerfile
volumes:
- './app'
- './app/node_modules'
ports:
- '4201:4200'
FROM node
WORKDIR /app
ENV PATH /app/node_modules/.bin:$PATH
COPY package.json /app/package.json
RUN npm i
RUN npm i -g @angular/cli --unsafe
COPY . /app
CMD ng serve --host 0.0.0.0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment