Skip to content

Commit

Permalink
ci: travis -> buildkite
Browse files Browse the repository at this point in the history
  • Loading branch information
boz committed Jun 29, 2018
1 parent 8ab4af8 commit 37bc8e1
Show file tree
Hide file tree
Showing 4 changed files with 62 additions and 61 deletions.
32 changes: 31 additions & 1 deletion .buildkite/pipeline.yml
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
env:
AKASH_GO_PACKAGE: "github.com/ovrclk/akash"
TEST_DELAY_THREAD_START: 10ms
TEST_DELAY_THREAD_START: 20ms
steps:

- name: ":ferris_wheel: tests"
plugins:
golang#v2.0.0:
version: "1.10"
import: "${AKASH_GO_PACKAGE}"
environment:
- TEST_DELAY_THREAD_START
command: .buildkite/script/test.sh test

- name: ":popcorn: coverage"
Expand All @@ -16,6 +18,7 @@ steps:
version: "1.10"
import: "${AKASH_GO_PACKAGE}"
environment:
- TEST_DELAY_THREAD_START
- CI
- BUILDKITE
- BUILDKITE_BRANCH
Expand All @@ -33,3 +36,30 @@ steps:
version: "1.10"
import: "${AKASH_GO_PACKAGE}"
command: .buildkite/script/test.sh integration

- name: ":hospital: hygiene checks"
plugins:
golang#v2.0.0:
version: "1.10"
import: "${AKASH_GO_PACKAGE}"
command: .buildkite/script/test.sh lint

- name: ":satellite: golang with rc"
branches: master
plugins:
golang#v2.0.0:
version: "rc"
import: "${AKASH_GO_PACKAGE}"
environment:
- TEST_DELAY_THREAD_START
command: .buildkite/script/test.sh test-lite

- name: ":wilted_flower: golang with 1.9"
branches: master
plugins:
golang#v2.0.0:
version: "1.9"
import: "${AKASH_GO_PACKAGE}"
environment:
- TEST_DELAY_THREAD_START
command: .buildkite/script/test.sh test-lite
33 changes: 29 additions & 4 deletions .buildkite/script/test.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
#!/bin/bash

set -euo pipefail

do_glide(){
echo "--- :building_construction: installing glide"
curl https://glide.sh/get | sh
Expand All @@ -14,13 +16,27 @@ do_bins(){
}

do_vet(){
echo "--- :mag: linting"
echo "--- :female-police-officer::skin-tone-4: vet"
make test-vet
}

do_lint(){
echo "--- :building_construction: installing lint deps"
make lintdeps-install

echo "--- :mag: linting"
make test-lint || {
echo "--- :rotating_light: excessive lint errors"
}
}

do_tests(){
echo "--- :female-scientist: runnig unit tests"
# make test-full
make test-full
}

do_tests_lite(){
echo "--- :female-scientist: runnig unit tests"
make test
}

Expand All @@ -43,10 +59,13 @@ do_integration(){
case "$1" in
test)
do_glide
do_bins
do_vet
do_tests
;;
test-lite)
do_glide
do_bins
do_tests_lite
;;
coverage)
do_glide
do_coverage
Expand All @@ -55,4 +74,10 @@ case "$1" in
do_glide
do_integration
;;
lint)
do_glide
do_bins
do_vet
do_lint
;;
esac
54 changes: 0 additions & 54 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,51 +12,6 @@ env:
jobs:
include:

# linux/1.9: collect & submit test coverage
- name: test
os: linux
go: 1.9
script:
- make build
- make test-vet
- make coverdeps-install
- make test-cover

# linux/1.10 (mainline): tests, integration, image-bins
- name: test
os: linux
go: "1.10"
script:
- make build
- make test-vet
- make test
- make integrationdeps-install
- make test-integration
- make image-bins

# linux/1.10 (mainline): print linting errors
- name: test-lint
os: linux
go: "1.10"
allow_failures: true
script:
- make lintdeps-install
- make test-lint
if: type = cron

# linux/master: tests, integration, image-bins
- name: test
os: linux
go: master
script:
- make build
- make test-vet
- make test
- make integrationdeps-install
- make test-integration
- make image-bins
if: type = cron

# osx/1.10: tests, integration, image-bins
- name: test
os: osx
Expand All @@ -71,15 +26,6 @@ jobs:
- make image-bins
if: type = cron

# linux/1.10 (mainline): build image
- name: image
os: linux
go: "1.10"
services: [docker]
script:
- make image
if: type = cron

# linux/1.10 (mainline): run skipped tests
- name: test-skipped
os: linux
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[![Akash](_docs/img/logo-label-black.svg "Akash")](#overview)
[![Build Status](https://travis-ci.org/ovrclk/akash.svg?branch=master)](https://travis-ci.org/ovrclk/akash)
[![Coverage Status](https://coveralls.io/repos/github/ovrclk/akash/badge.svg?branch=master)](https://coveralls.io/github/ovrclk/akash?branch=master)
[![Build status](https://badge.buildkite.com/85e140e3e8c0257c63d976946b061b805f0f338cdca7b02a9c.svg)](https://buildkite.com/ovrclk/akash)
[![Coverage](https://codecov.io/gh/ovrclk/akash/branch/master/graph/badge.svg)](https://codecov.io/gh/ovrclk/akash)
[![Go Report Card](https://goreportcard.com/badge/github.com/ovrclk/akash)](https://goreportcard.com/report/github.com/ovrclk/akash)

# Overview
Expand Down

0 comments on commit 37bc8e1

Please sign in to comment.