add frontend (#5)

添加前端页面
This commit is contained in:
Sakurasan
2023-05-13 05:01:35 +08:00
committed by GitHub
parent 9339cab328
commit 70168fd01e
22 changed files with 2046 additions and 6 deletions

View File

@@ -1,7 +1,13 @@
FROM node:18.12.1-alpine3.16 AS frontend
WORKDIR /frontend-build
COPY ./web/ .
RUN npm install && npm run build && rm -rf node_modules
FROM golang:1.19.7-alpine as builder
LABEL anther="github.com/Sakurasan"
RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.aliyun.com/g' /etc/apk/repositories && apk --no-cache add make cmake upx
WORKDIR /build
COPY --from=frontend /frontend-build/dist /build/dist
COPY . /build
ENV GO111MODULE=on
# ENV GOPROXY=https://goproxy.cn,direct