forked from request-yo-racks/web
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile.dev
More file actions
27 lines (20 loc) · 831 Bytes
/
Copy pathDockerfile.dev
File metadata and controls
27 lines (20 loc) · 831 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
FROM node:8.9.4-alpine as builder
MAINTAINER Rémy Greinhofer <remy.greinhofer@gmail.com>
# Add Git (required by polymer-cli).
RUN apk add --update bash git make
# Go to the directory holding the application and copy the source code.
WORKDIR /usr/src/app
COPY . .
RUN mv /usr/src/app/src/config-dev.js /usr/src/app/src/config.js \
&& rm -fr web/bower_components
# Install bower, polymer-cli and build the project.
RUN make bootstrap-npm \
&& polymer install \
&& make dist
# Create the release image by serving the project previously built using nginx.
FROM nginx:1.13.8-alpine
MAINTAINER Rémy Greinhofer <remy.greinhofer@gmail.com>
# Copy custom configuration file..
COPY docker/nginx/ /etc/nginx/
# Copy the bundled version of the site.
COPY --from=builder /usr/src/app/build/es5-bundled /var/www/build/es6-bundled