drone 1 format

This commit is contained in:
Sebastian Frank
2019-02-20 11:58:41 +01:00
parent 2115452e34
commit 93cf5fc0d3

View File

@@ -1,60 +1,59 @@
workspace:
base: /go
path: src/gitbase.de/apairon/mark2web
kind: pipeline
name: default
pipeline:
build_mark2web_linux:
steps:
- name: build for linux
image: golang:latest
environment:
- CGO_ENABLED=0
- GOOS=linux
- GOARCH=amd64
CGO_ENABLED: 0
GOOS: linux
GOARCH: amd64
commands:
- git submodule update --init --recursive
- git fetch --tags
- ./build.sh
test_example:
- name: test with example content
image: alpine
commands:
- ./dist/mark2web-`cat VERSION`-linux-amd64 -version
- ./dist/mark2web-`cat VERSION`-linux-amd64 -in example -out example_out -create -logLevel debug
build_mark2web_freebsd:
- name: build for freebsd
image: golang:latest
environment:
- CGO_ENABLED=0
- GOOS=freebsd
- GOARCH=amd64
CGO_ENABLED: 0
GOOS: freebsd
GOARCH: amd64
commands:
- ./build.sh
when:
event: [ tag ]
build_mark2web_darwin:
- name: build for macos
image: golang:latest
environment:
- CGO_ENABLED=0
- GOOS=darwin
- GOARCH=amd64
CGO_ENABLED: 0
GOOS: darwin
GOARCH: amd64
commands:
- ./build.sh
when:
event: [ tag ]
build_mark2web_windows:
- name: build for windows
image: golang:latest
environment:
- CGO_ENABLED=0
- GOOS=windows
- GOARCH=amd64
- FILEEXT=.exe
CGO_ENABLED: 0
GOOS: windows
GOARCH: amd64
FILEEXT: .exe
commands:
- ./build.sh
when:
event: [ tag ]
build_docker:
- name: build docker image
image: docker
commands:
- cp dist/mark2web-`cat VERSION`-linux-amd64 mark2web
@@ -65,7 +64,7 @@ pipeline:
branch: [ master ]
event: [ push ]
deploy_website:
- name: deploy website
image: apairon/mark2web:latest
commands:
- /mark2web -version
@@ -74,7 +73,7 @@ pipeline:
branch: [ master ]
event: [ push ]
prepare_release:
- name: prepare release
image: apairon/mark2web:latest
commands:
- gzip dist/*
@@ -82,16 +81,18 @@ pipeline:
when:
event: [ tag ]
gitea_relase:
- name: gitea release
image: plugins/gitea-release
secrets: [ plugin_api_key ]
base_url: https://gitbase.de
files:
- dist/*
title: VERSION
note: RELEASE
checksum:
- md5
- sha256
settings:
api_key:
from_secret: gitea_token
base_url: https://gitbase.de
files:
- dist/*
title: VERSION
note: RELEASE
checksum:
- md5
- sha256
when:
event: [ tag ]