'codecgen' embeds a random integer in each identifier; this means code
coverage across different CircleCI lanes may not match.
Here we force the integer to 23 on every CircleCI build so they always match.
There are two source checkouts in circle, and we were building in the wrong one
(ie. not the one where the earlier build happened). This was wasteful at best
and buggy at worst due to build differences.
Update the build-tools introduced a regression while building on circle
ci.
The PR https://github.com/weaveworks/build-tools/pull/73 is compatible
with python requests module `>=v2.4.2`. We need to provide a more
updated version of the one available in ubuntu 12.04 or 14.04
repositories.
Change the owner of "$HOME/.bashrc.backup" as the Google cloud cli wants
to backup to this file during setup and it's owned by root in the Circle
CI image.
Second, allow writes to `/usr/local/go/pkg` for `go install net` to
work.
After this patch, circleci builds the traffic control plugin image and
pushes it on docker hub. Rename traffic control plugin docker image
to "weaveworks/scope-traffic-control-plugin".
* Squashed 'tools/' changes from e9e7e6b..db5efc0
db5efc0 Merge pull request #28 from weaveworks/mike/add-image-tag
5312c40 Import image-tag script into build tools so it can be shared
7e850f8 Fix logs path
dda9785 Update deploy api
f2f4e5b Fix the wcloud client
3925eb6 Merge pull request #27 from weaveworks/wcloud-events
77355b9 Lint
d9a1c6c Add wcloud events, update flags and error nicely when there is no config
git-subtree-dir: tools
git-subtree-split: db5efc0537
* Remove ./image-tag and use ./tools/image-tag instead
image-tag is now shared code from the build-tools repo
After https://github.com/weaveworks/scope/commit/e2441623 "wcloud
deploy" is run in the main deploy unit guarded by the environment
variable. But the test makes it fail when it is not run under
"weaveworks".
* circle.yml: deploy master with non-upstream hub accounts
Since b4abe582f4, images are tagged on
Docker Hub. But this was not working for non-upstream Docker Hub
accounts. This patch should fix that.
Symptoms: https://circleci.com/gh/kinvolk/scope/23
> The push refers to a repository [docker.io/kinvolk/scope] (len: 1)
> error getting tags for kinvolk/scope: Tag does not exist for
> master-b89e9ec
Also, ensure that the Docker tag name does not include any '/'.
Symptoms: https://circleci.com/gh/kinvolk/scope/24
> docker tag weaveworks/scope weaveworks/scope:alban/hub1-ef739d9
> repository name component must match "[a-z0-9]+(?:[._-][a-z0-9]+)*"
* extras/in_parallel.sh: ensure unique schedule name
Use CircleCI environment variables as documented on:
https://circleci.com/docs/environment-variables/
Symptoms:
> $ cd $SRCDIR/extras; ./build_on_circle.sh
> Doing graphviz/graphviz
> make: *** No rule to make target `graphviz/graphviz'. Stop.
See: https://github.com/weaveworks/scope/pull/1655#issuecomment-232696357
* circle.yml: separate wcloud deployment
Do not run wcloud for non-weaveworks builds, as suggested by
https://github.com/weaveworks/scope/pull/1655#discussion_r71179373
By default, non-master branches are not deployed on the Docker Hub. With
this patch, you can enable this feature by setting the environment
variable DEPLOY_BRANCH in the circle configuration.
It will not be tagged with the "latest" tag but instead derive the tag
from the branch name. Since "/" are not allowed in Docker tag names, all
"/" are replaced by "-".
When testing code in Scope, I use circle to build the Docker image but I
don't want to always use my "master" branch for development.
With this patch, CircleCI will push by default to the Docker repository
$DOCKER_ORGANIZATION/scope. If $DOCKER_ORGANIZATION is not defined, it
will use $DOCKER_USER/scope.