feat(打包): 项目信息的修改以及打包脚本的编写
This commit is contained in:
parent
947718c5f6
commit
0fde21c0ec
2
.gitignore
vendored
2
.gitignore
vendored
@ -1,2 +1,2 @@
|
||||
yuchat-proxy-server
|
||||
yuchat-proxy-client.exe
|
||||
*.exe
|
||||
@ -1,8 +1,13 @@
|
||||
from docker.yuchat.top/golang:1.21-alpine AS builder
|
||||
workdir /app
|
||||
COPY . .
|
||||
RUN go mod tidy && go build -o yuchat-proxy-server server/main.go
|
||||
|
||||
from docker.yuchat.top/alpine:3.11
|
||||
|
||||
workdir /app
|
||||
expose 8080
|
||||
|
||||
add yuchat-proxy-server /app
|
||||
copy --from=builder /app/yuchat-proxy-server /app/yuchat-proxy-server
|
||||
|
||||
entrypoint ["./yuchat-proxy-server"]
|
||||
2
build-client.bat
Normal file
2
build-client.bat
Normal file
@ -0,0 +1,2 @@
|
||||
go mod tidy
|
||||
go build -o yuchat-proxy-client.exe client/main.go
|
||||
@ -3,7 +3,7 @@ package main
|
||||
import (
|
||||
"log"
|
||||
"net"
|
||||
"test-proxy-go/common"
|
||||
"yuchat-proxy/common"
|
||||
|
||||
"github.com/gorilla/websocket"
|
||||
)
|
||||
|
||||
4
go.mod
4
go.mod
@ -1,5 +1,5 @@
|
||||
module test-proxy-go
|
||||
module yuchat-proxy
|
||||
|
||||
go 1.21.0
|
||||
|
||||
require github.com/gorilla/websocket v1.5.3 // indirect
|
||||
require github.com/gorilla/websocket v1.5.3
|
||||
|
||||
@ -6,7 +6,7 @@ import (
|
||||
"log"
|
||||
"net"
|
||||
"net/http"
|
||||
"test-proxy-go/common"
|
||||
"yuchat-proxy/common"
|
||||
|
||||
"github.com/gorilla/websocket"
|
||||
)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user