mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-20 08:30:12 +01:00
🎨 Use golang:latest to build image
This commit is contained in:
parent
3f38302731
commit
4d5f538008
1 changed files with 2 additions and 3 deletions
|
|
@ -3,13 +3,12 @@ WORKDIR /go/src/github.com/siyuan-note/siyuan/
|
||||||
ADD . /go/src/github.com/siyuan-note/siyuan/
|
ADD . /go/src/github.com/siyuan-note/siyuan/
|
||||||
RUN cd app && npm install -g pnpm && pnpm install && pnpm run build
|
RUN cd app && npm install -g pnpm && pnpm install && pnpm run build
|
||||||
|
|
||||||
FROM golang:alpine as GO_BUILD
|
FROM golang:latest as GO_BUILD
|
||||||
WORKDIR /go/src/github.com/siyuan-note/siyuan/
|
WORKDIR /go/src/github.com/siyuan-note/siyuan/
|
||||||
COPY --from=NODE_BUILD /go/src/github.com/siyuan-note/siyuan/ /go/src/github.com/siyuan-note/siyuan/
|
COPY --from=NODE_BUILD /go/src/github.com/siyuan-note/siyuan/ /go/src/github.com/siyuan-note/siyuan/
|
||||||
ENV GO111MODULE=on
|
ENV GO111MODULE=on
|
||||||
ENV CGO_ENABLED=1
|
ENV CGO_ENABLED=1
|
||||||
RUN apk add --no-cache gcc musl-dev && \
|
RUN cd kernel && go build --tags fts5 -v -ldflags "-s -w -X github.com/siyuan-note/siyuan/kernel/util.Mode=prod" && \
|
||||||
cd kernel && go build --tags fts5 -v -ldflags "-s -w -X github.com/siyuan-note/siyuan/kernel/util.Mode=prod" && \
|
|
||||||
mkdir /opt/siyuan/ && \
|
mkdir /opt/siyuan/ && \
|
||||||
mv /go/src/github.com/siyuan-note/siyuan/app/appearance/ /opt/siyuan/ && \
|
mv /go/src/github.com/siyuan-note/siyuan/app/appearance/ /opt/siyuan/ && \
|
||||||
mv /go/src/github.com/siyuan-note/siyuan/app/stage/ /opt/siyuan/ && \
|
mv /go/src/github.com/siyuan-note/siyuan/app/stage/ /opt/siyuan/ && \
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue