summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDee Luo <[email protected]>2019-11-06 22:29:04 +0800
committerHaishan <[email protected]>2019-11-06 22:29:04 +0800
commit2c8a80b499ee5cf524a8caffe741441e7b7d857e (patch)
treea72b07c3a4df11cc37430a3d11c133b3a2e49d2d
parent4946f30243c18c412e628c0fc300048b5a08a103 (diff)
add docker support (#279)
-rw-r--r--Dockerfile9
1 files changed, 9 insertions, 0 deletions
diff --git a/Dockerfile b/Dockerfile
new file mode 100644
index 0000000..ea33239
--- /dev/null
+++ b/Dockerfile
@@ -0,0 +1,9 @@
+FROM node:alpine AS builder
+WORKDIR /app
+COPY . .
+RUN yarn && yarn run build
+
+FROM nginx:alpine
+RUN rm -rf /usr/share/nginx/html/*
+COPY --from=builder /app/public /usr/share/nginx/html
+CMD ["nginx", "-g", "daemon off;"]