Add Travis CI build

This commit is contained in:
Stefan Prodan
2018-09-24 20:28:45 +03:00
parent 59c98a9669
commit e5d198f110
3 changed files with 30 additions and 2 deletions

26
.travis.yml Normal file
View File

@@ -0,0 +1,26 @@
sudo: required
language: go
go:
- 1.10.x
services:
- docker
addons:
apt:
packages:
- docker-ce
script:
- make test
- make verify-codegen
- make build
after_success:
- if [ ! -s "$TRAVIS_TAG" ]; then
docker tag stefanprodan/steerer:latest stefanprodan/steerer:$TRAVIS_TAG;
echo $DOCKER_PASS | docker login -u=$DOCKER_USER --password-stdin;
docker push stefanprodan/steerer:latest;
docker push stefanprodan/steerer:$TRAVIS_TAG;
fi

View File

@@ -1,5 +1,7 @@
# steerer
[![Build Status](https://travis-ci.org/stefanprodan/steerer.svg?branch=master)](https://travis-ci.org/stefanprodan/steerer)
Steerer is a Kubernetes operator that automates the promotion of canary deployments
using Istio routing for traffic shifting and Prometheus metrics for canary analysis.
@@ -86,7 +88,7 @@ kubectl -n test describe rollout/podinfo
Events:
Type Reason Age From Message
---- ------ ---- ---- -------
Normal Synced 3m steerer Stating rollout for podinfo.test
Normal Synced 3m steerer Starting rollout for podinfo.test
Normal Synced 3m steerer Advance rollout podinfo.test weight 10
Normal Synced 3m steerer Advance rollout podinfo.test weight 20
Normal Synced 2m steerer Advance rollout podinfo.test weight 30

View File

@@ -51,7 +51,7 @@ func (c *Controller) advanceDeploymentRollout(name string, namespace string) {
// skip HTTP error rate check when no traffic is routed to canary
if canaryRoute.Weight == 0 {
c.recordEventInfof(r, "Stating rollout for %s.%s", r.Name, r.Namespace)
c.recordEventInfof(r, "Starting rollout for %s.%s", r.Name, r.Namespace)
} else {
if ok := c.checkDeploymentSuccessRate(r); !ok {
return