prepare release
All checks were successful
the build was successful

This commit is contained in:
Sebastian Frank 2019-02-20 09:12:25 +01:00
parent b38ba11b6b
commit 97432a5daf
Signed by: apairon
GPG Key ID: 7270D06DDA7FE8C3
3 changed files with 48 additions and 5 deletions

View File

@ -12,12 +12,37 @@ pipeline:
commands:
- ./build.sh
build_website:
test_example:
image: alpine
commands:
- ls -la
- ./dist/mark2web-linux-amd64 -version
- ./dist/mark2web-linux-amd64 -in website -out html -create -logLevel debug
- ./dist/mark2web-linux-amd64 -in example -out example_out -create -logLevel debug
build_mark2web_freebsd:
image: golang:latest
environment:
- CGO_ENABLED=0
- GOOS=freebsd
- GOARCH=amd64
commands:
- ./build.sh
when:
branch: master
event: push
build_mark2web_windows:
image: golang:latest
environment:
- CGO_ENABLED=0
- GOOS=windows
- GOARCH=amd64
- FILEEXT=.exe
commands:
- ./build.sh
when:
branch: master
event: push
build_docker:
image: docker
@ -27,4 +52,22 @@ pipeline:
- /var/run/docker.sock:/var/run/docker.sock
when:
branch: master
event: push
event: push
deploy_website:
image: apairon/mark2web:latest
commands:
- ls -la
- /mark2web -version
- /mark2web -in website -out html -create -logLevel debug
when:
branch: master
event: push
prepare_release:
image: apairon/mark2web:latest
commands:
- ls -la dist/
- gzip dist/*
- ls -la dist/

View File

@ -1,4 +1,4 @@
FROM alpine
RUN apk update && apk add openssh-client sshpass rsync && rm -r /var/cache/
RUN apk update && apk add openssh-client sshpass rsync gzip && rm -r /var/cache/
ADD dist/mark2web-linux-amd64 /mark2web
CMD ["/mark2web"]

View File

@ -1,4 +1,4 @@
#!/bin/sh
mkdir -p dist
go build -v -ldflags "-X main.Version=`cat VERSION` -X main.GitHash=`git rev-parse HEAD` -X main.BuildTime=`date -u '+%Y-%m-%d_%I:%M:%S%p'`" -o dist/mark2web-${GOOS}-${GOARCH}${ext}
go build -v -ldflags "-X main.Version=`cat VERSION` -X main.GitHash=`git rev-parse HEAD` -X main.BuildTime=`date -u '+%Y-%m-%d_%I:%M:%S%p'`" -o dist/mark2web-${GOOS}-${GOARCH}${FILEEXT}