diff options
Diffstat (limited to 'build')
| -rw-r--r-- | build | 16 |
1 files changed, 16 insertions, 0 deletions
@@ -0,0 +1,16 @@ +#!/bin/bash + +DOCKER_USER=docker.io +date=$(date "+%Y%m%d%H%M") +version="v1.0.0_$date" +: ${DOCKER_USER:? required} + +export GO111MODULE=on +export GOPROXY=https://goproxy.cn +# build webhook +CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -o webhook-example +# build docker image +docker build --no-cache -t ${DOCKER_USER}/webhook-example:${version} . +rm -rf webhook-example + +#docker push ${DOCKER_USER}/webhook-example:${version} |
