refactor: build

master
howell 4 years ago
parent 3cd6ce82b9
commit 92dab844ac

@ -10,20 +10,6 @@ steps:
- echo "172.31.211.15 git.oa00.com" >> /etc/hosts
- git clone $DRONE_REMOTE_URL .
- git checkout $DRONE_COMMIT
- name: restore-cache
image: meltwater/drone-cache
settings:
backend: filesystem
restore: true
cache_key: "gomod"
archive_format: gzip
filesystem_cache_root: "/var/lib/cache"
mount:
- 'mod.pkg'
volumes:
- name: cache
path: "/var/lib/cache"
# Do stuff..
- name: build
image: golang:1.16-alpine3.13
environment:
@ -31,19 +17,6 @@ steps:
commands:
- GOPROXY=https://goproxy.cn go get -u github.com/go-bindata/go-bindata/...@v3.1.2
- GOPROXY=https://goproxy.cn CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags "-X recook/configs.environment=release" -tags=jsoniter -v -o ./recook ./main.go
- name: rebuild-cache
image: meltwater/drone-cache
settings:
backend: filesystem
rebuild: true
cache_key: "gomod"
archive_format: gzip
filesystem_cache_root: "/var/lib/cache"
mount:
- 'mod.pkg'
volumes:
- name: cache
path: "/var/lib/cache"
- name: scp files
image: appleboy/drone-scp
settings:

@ -755,7 +755,5 @@ func routerManage(manageRouter *gin.RouterGroup) {
auditGysPurchaseRouter.POST("cal_rote", auditPurController.CalculateRote) //计算
}
}
}

Loading…
Cancel
Save