gns3-web-ui/Dockerfile

27 lines
511 B
Docker
Raw Normal View History

2018-02-21 12:21:32 +00:00
# Dockerfile for GNS3 Web-ui development
2020-10-11 07:30:47 +00:00
FROM node:stretch
2018-02-21 12:21:32 +00:00
# Create user
RUN useradd --user-group --create-home --shell /bin/false gns3-web-ui
# Create app directory
ENV HOME /home/gns3-web-ui
WORKDIR $HOME
# Copy source
COPY . .
2018-02-22 10:49:03 +00:00
RUN chown -R gns3-web-ui:gns3-web-ui $HOME
# Switch to gns3-web-ui user
USER gns3-web-ui
2018-02-21 12:21:32 +00:00
# Install dependencies
2018-02-22 10:49:03 +00:00
RUN yarn global add @angular/cli
RUN yarn install --pure-lockfile
ENV PATH /home/gns3-web-ui/.yarn/bin:$PATH
2018-02-21 12:21:32 +00:00
EXPOSE 8080
CMD ng serve --host 0.0.0.0 --port 8080