Commit Graph

169 Commits (65c14a1b09f0f687b9dc63ddf16a40031abcd2ab)

Author SHA1 Message Date
Filipe Brandenburger 30db3e281d Cleanup hack/test-integration.sh
Proper quoting, error checks, use $KUBE_* variables when applicable, trap to do
cleanup on all errors, call cleanup explicitly on successful exit.

Tested:
- Ran it manually to completion, test run successful.
- Interrupted it during the run, checked that $? was non-zero, etcd was killed.

Signed-off-by: Filipe Brandenburger <filbranden@google.com>
2014-09-23 09:37:29 -07:00
Eric Paris a96d16f8c0 Allow option to not build cmd/integration
In case it was built seperately (as in, on Fedora, we cannot use go
install as we do not have write permission to portions of the GOPATH)
2014-09-23 11:56:26 -04:00
Eric Paris 3a40db8f56 hack: Switch some $(dirname $0)../blah to use ${KUBE_*} vars
This doesn't fix anything broken. But we have config-go which exports
KUBE_REPO_ROOT and KUBE_TARGET.  Using those means the test scripts can
be more easily moved around the repo and still work.  Especially in
hack/test-integration.sh where we use hack/build-go.sh which is going
to use KUBE_TARGET to place the binary, then we use a different method
to find/execute the binary...
2014-09-23 10:10:55 -04:00
Tim Hockin cf86d66076 rename labels in kubcfg logic 2014-09-22 15:34:13 -07:00
Clayton Coleman 463a16af36 Add benchmarks for API tests 2014-09-19 17:17:54 -04:00
Clayton Coleman 54e0af8b96 Allow -race to be disabled in test-go.sh 2014-09-19 14:09:42 -04:00
Clayton Coleman 27bbd7df56 Increase the hack/test-go.sh timeout to account for more fuzzing
We fuzz v1beta1 and v1beta2 now, so fuzzer takes twice as long.
2014-09-18 14:17:32 -04:00
Jessica Forrester 2dc30aa932 Remove unused enable_cors flag and allow localhost without a port as an origin in local-up-cluster 2014-09-12 13:01:32 -04:00
Filipe Brandenburger fabf7c7f55 Fix the e2e scripts after PR 1284 which added a new file. 2014-09-11 15:32:11 -07:00
Daniel Smith 6757b402d5 Merge pull request #1133 from jwforres/enable_cors
Add option to enable a simple CORS implementation for the api server
2014-09-11 13:59:14 -07:00
Eric Paris d687156154 Try to document all environment variable used by config-go.sh 2014-09-10 17:16:27 -04:00
Eric Paris df5fe66636 KUBE_NO_GODEPS to not use in tree godeps
If this is set, and it normally shouldn't be, the config file will not
add the in tree Godeps to the GOPATH.  So all of them must be solved by
the KUBE_EXTRA_GOPATH
2014-09-10 16:51:23 -04:00
Eric Paris 35f03d4241 KUBE_EXTRA_GOPATH to append to the GOPATH
So you can add your own package to the GOPATH outside of the kube tree
2014-09-10 16:47:57 -04:00
Eric Paris e426dd78a1 function to turn list of targets to list of go packages 2014-09-10 13:16:45 -04:00
Eric Paris 4ba97e3968 Move default target list from build_go to config_go 2014-09-10 12:20:50 -04:00
Jessica Forrester 8b4ca9c2a7 Move CORS handler wrapping into cmd/apiserver and switch config flag to a list of allowed origins 2014-09-09 17:50:18 -04:00
Jessica Forrester 8723eece49 Add option to enable a simple CORS implementation for the api server 2014-09-09 17:50:18 -04:00
Daniel Smith d397d64b9e go test -cover -race is fixed now 2014-09-09 14:06:23 -07:00
Dan Mace 2e1d62ac65 Typo correction 2014-09-08 20:23:30 -04:00
Joe Beda 073327277b Fix label query in e2e basic.sh 2014-09-05 14:10:02 -07:00
Joe Beda 1410724031 Fix up some flaky behavior of the new improved update e2e test. 2014-09-05 13:04:31 -07:00
Daniel Smith ee1c0838d8 Merge pull request #1142 from jbeda/tweak-demo
Improve update demo, support rolling template update
2014-09-05 10:07:58 -07:00
Filipe Brandenburger be322fc5da Merge pull request #1174 from eparis/version-shell-overrides
Allow setting of git_commit, version, and dirty via shell varables
2014-09-05 09:26:01 -07:00
Eric Paris 428e0aaff0 Allow setting of git_commit, version, and dirty via shell varables
This is particularly useful if building from a tarball instead of from a
checked out git repo (as all Linux distributions do)
2014-09-05 11:48:04 -04:00
Eric Paris c7e8e05706 Capitalize bash variable and prefix with KUBE_
We intend to make these setable by the environment.  This just does the
renaming.
2014-09-05 11:42:51 -04:00
Eric Paris 78b82382cf default to build all binaries even if build options given 2014-09-05 10:07:10 -04:00
Joe Beda ce34eacd2c Fix up e2e test for update demo.
Use the scripts that are in the example directory.  Also actually run the update as part of the test.
2014-09-04 13:25:39 -07:00
Joe Beda c47b405841 Use KUBECFG instead of CLOUDCFG in scripts 2014-09-04 13:25:39 -07:00
Andriy Yurchuk 22ce0022d1 Merge branch 'master' into build-go-verbose 2014-09-04 22:16:24 +03:00
Brendan Burns 4a934427db Exclude vendored etcd. 2014-09-04 12:05:34 -07:00
Andriy Yurchuk 24d0eb43ec Merge branch 'master' into build-go-verbose 2014-09-04 21:27:15 +03:00
Dawn Chen 87278a6f56 Merge pull request #1179 from brendandburns/fix
Fix travis and cluster installs.
2014-09-04 10:32:45 -07:00
Brendan Burns 3864cf453a Fix travis and cluster installs. 2014-09-04 10:31:09 -07:00
Brendan Burns 78df593c57 Fix a shell typo. 2014-09-04 10:03:49 -07:00
Tim Hockin 512b0ab90a Merge pull request #1176 from brendandburns/travis
Re-enable travis for Go tip
2014-09-04 09:57:14 -07:00
Brendan Burns 53e3bff464 Re-enable travis for Go tip 2014-09-04 09:56:28 -07:00
Andriy Yurchuk 5878794fd7 Be a little more verbose while building local go 2014-09-04 13:25:16 +03:00
Filipe Brandenburger 3d03b4b80f Also assume arguments starting with dashes are go flags in `hack/build-go.sh`
Tested:
  $ hack/build-go.sh cmd/kubelet -v
  github.com/GoogleCloudPlatform/kubernetes/pkg/...

Signed-off-by: Filipe Brandenburger <filbranden@google.com>
2014-09-03 14:59:29 -07:00
Filipe Brandenburger 8effbdc63f In `hack/test-go.sh` treat arguments that start with a dash as go flags.
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>
2014-09-03 14:57:19 -07:00
Tim Hockin 640a1d323d Improve test script
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"
2014-09-03 09:40:20 -07:00
Filipe Brandenburger b94749ec70 Set gitMajor and gitMinor from hack/build-go.sh
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>
2014-09-02 16:23:31 -07:00
Filipe Brandenburger 8cd7387cc0 Include `-dirty` suffix in version info when building on a dirty tree
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>
2014-09-02 16:23:31 -07:00
Joe Beda 843ae1fbe2 Rename `output/` directory to `_output/`
go build ./... will ignore any directory starting with an underscore.
2014-08-29 14:44:55 -07:00
Tim Hockin f0c3896281 Build tweaks
Wrap long lines.
Add GOFLAGS support to build and test.
Comments.
2014-08-28 22:56:00 -07:00
Deyuan Deng c63205b0a7 Add quotes for variable; change shell redirection. 2014-08-28 22:31:53 -04:00
Deyuan Deng 9fed990da6 Start scheduler locally. 2014-08-28 20:48:36 -04:00
Daniel Smith e2895c3bd8 Merge pull request #1055 from brendandburns/flake
Add the ability to multiple test iterations without rebuilding.
2014-08-28 10:31:44 -07:00
Daniel Smith 8072f69a4c Merge pull request #1054 from filbranden/build_without_godep
Build without godep
2014-08-28 10:07:05 -07:00
Ryan Richard 2565164a8d Add Rackspace support for dev-build-and-up 2014-08-28 10:36:58 -05:00
Brendan Burns 9fce47ac68 Add the ability to multiple test iterations without rebuilding.
Address comments.
2014-08-27 22:07:40 -07:00