We created a name=<controller name> label on each object we created. This was confusing. Instead, piggyback on `replicationController` label and use that as the selector.
This fixes `hack/test-go.sh pkg/apiserver -test.run=<a_specific_test_name>`
which was broken by PR #1116.
Signed-off-by: Filipe Brandenburger <filbranden@google.com>
Uncomment docker service state as it should no longer be affected by race bug in docker init.d start script. Also make sure that the docker service state depends on the cbr state.
Fixes#802
add usage
verify flag value for -i is numeric
allow multiple targets on the command line
actually capture coverage output
fix lingering GOFLAGS undef issue
fix issue with -i not working at all: ((x++)) returns 1 when x is 0, which is
incompatible with "set -e"
Set the values of major and minor version based on the output of the
`git describe` command, which uses annotated tags as source of
versioning information.
Minor will get a "+" appended whenever the annotated tag does not match
the tree exactly (including when the tree is dirty.) So that only
official releases will have a "bare" minor version, all others will have
a "+" to indicate the binaries contain changes from the released version
in minor.
(This is similar to how versions of development builds of the Linux
kernel work.)
Tested:
- With no annotated tags:
$ hack/build-go.sh
$ _output/go/bin/kubecfg -version=raw
version.Info{Major:"0", Minor:"1+", GitVersion:"v0.1+", GitCommit:"7d29873bdee87efacaace30ab3602297cacf1b4f", GitTreeState:"clean"}
- Tagging current version on a clean git tree:
$ git tag -a -m 'Test tag v2.3' v2.3
$ hack/build-go.sh
$ _output/go/bin/kubecfg -version=raw
version.Info{Major:"2", Minor:"3", GitVersion:"v2.3", GitCommit:"7d29873bdee87efacaace30ab3602297cacf1b4f", GitTreeState:"clean"}
- Tagging current version on a dirty git tree:
$ git tag -a -m 'Test tag v2.3' v2.3
$ touch test.txt # this is enough to mark the tree as dirty
$ hack/build-go.sh
$ _output/go/bin/kubecfg -version=raw
version.Info{Major:"2", Minor:"3+", GitVersion:"v2.3-dirty", GitCommit:"7d29873bdee87efacaace30ab3602297cacf1b4f", GitTreeState:"dirty"}
- Tagging a previous version on a clean tree:
$ git tag -a -m 'Test tag v2.3' v2.3 HEAD~5
$ hack/build-go.sh
$ _output/go/bin/kubecfg -version=raw
version.Info{Major:"2", Minor:"3+", GitVersion:"v2.3-6-g7d29873bdee87e", GitCommit:"7d29873bdee87efacaace30ab3602297cacf1b4f", GitTreeState:"clean"}
Signed-off-by: Filipe Brandenburger <filbranden@google.com>
Ensure the output of `git describe` will include the `-dirty` suffix
when building on a tree with modified files in it.
Tested:
- ...
Signed-off-by: Filipe Brandenburger <filbranden@google.com>