upgrade: .devops/gitlink正式环境

This commit is contained in:
yystopf 2023-04-08 14:28:14 +08:00
parent cf1341d559
commit db7072abac
1 changed files with 17 additions and 8 deletions

View File

@ -30,22 +30,31 @@ workflow:
- ref: golang_build_18_0 - ref: golang_build_18_0
name: golang构建 name: golang构建
on-failure: ignore on-failure: ignore
task: mafeibai/golang_build_18@0.0.5 image: golang:1.18.1-buster
input: input:
workspace: git_clone_0.git_path workspace: git_clone_0.git_path
bin_name: '"gitea"' script:
- apt-get install git -y
- cd $WORKSPACE
- go env -w CGO_ENABLED=0
- go env -w GOPROXY=https://goproxy.cn
- go mod tidy
- go mod vendor
- GOOS=linux GOARCH=amd64 go build -o gitea main.go
- echo done
needs: needs:
- git_clone_0 - git_clone_0
- ref: scp_resource_0 - ref: scp_resource_0
name: scp替换文件 name: scp替换文件
task: scp_resource@1.4.1 task: scp_resource@1.4.1
input: input:
ssh_ip: '""' workspace: git_clone_0.git_path
ssh_port: '"22"' ssh_private_key: ((ssh.siyao))
ssh_user: '"root"' ssh_ip: '"123.59.135.93"'
remote_file: '""' ssh_port: '"51123"'
local_file: '""' ssh_user: '"pdl"'
file_content: '""' remote_file: '"/home/pdl"'
local_file: '$WORKSPACE/gitea'
needs: needs:
- golang_build_18_0 - golang_build_18_0
- ref: end - ref: end