Compare commits

...

1 Commits

Author SHA1 Message Date
RecordingTheSmile 62dcac103f fix: Docker构建统一使用debian镜像 2025-11-06 21:25:28 +08:00
2 changed files with 5 additions and 5 deletions
+3 -3
View File
@@ -1,11 +1,11 @@
FROM golang:alpine AS backend-builder
RUN apk add --no-cache build-base
FROM golang:latest AS backend-builder
RUN apt install build-essential
WORKDIR /build
COPY . .
ENV CGO_ENABLED=1
RUN go build -ldflags="-s -w" -o bin/server
RUN apk add --no-cache upx
RUN apt install upx-ucl
RUN upx --best --lzma bin/server
+2 -2
View File
@@ -50,7 +50,7 @@ func Pass(err *error) {
if r := recover(); r != nil {
e, ok := errorx.ErrorFromPanic(r)
if ok {
*err = e
*err = oops.Wrap(e)
} else {
panic(r)
}
@@ -61,7 +61,7 @@ func HandleError(f func(error)) {
if r := recover(); r != nil {
e, ok := errorx.ErrorFromPanic(r)
if ok {
f(e)
f(oops.Wrap(e))
} else {
panic(r)
}