Skip to content

Commit

Permalink
Add RELEASE_INFRA_PUSH related code to support pushes from kubernetes…
Browse files Browse the repository at this point in the history
…/release.
  • Loading branch information
david-mcmahon committed Jul 14, 2016
1 parent f9a45e6 commit ae18034
Showing 1 changed file with 24 additions and 5 deletions.
29 changes: 24 additions & 5 deletions hack/jenkins/build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,11 @@ export KUBE_SKIP_CONFIRMATIONS=y
# Skip gcloud update checking
export CLOUDSDK_COMPONENT_MANAGER_DISABLE_UPDATE_CHECK=true

# FEDERATION?
: ${FEDERATION:="false"}
: ${RELEASE_INFRA_PUSH:="false"}
: ${KUBE_RELEASE_RUN_TESTS:="n"}
export KUBE_RELEASE_RUN_TESTS
export KUBE_RELEASE_RUN_TESTS RELEASE_INFRA_PUSH FEDERATION

# Clean stuff out. Assume the last build left the tree in an odd
# state.
Expand All @@ -54,9 +57,25 @@ git clean -fdx
# Build
go run ./hack/e2e.go -v --build

[[ ${KUBE_SKIP_PUSH_GCS:-} =~ ^[yY]$ ]] || {
# Push to GCS
./build/push-ci-build.sh
}
# Push to GCS?
if [[ ${KUBE_SKIP_PUSH_GCS:-} =~ ^[yY]$ ]]; then
echo "Not pushed to GCS..."
elif $RELEASE_INFRA_PUSH; then
git clone https://github.com/kubernetes/release $WORKSPACE/release
readonly release_infra_clone=$WORKSPACE/release

if [[ ! -x $release_infra_clone/push-ci-build.sh ]]; then
echo "FATAL: Something went wrong." \
"$release_infra_clone/push-ci-build.sh isn't available. Exiting..." >&2
exit 1
fi

$FEDERATION && federation_flag="--federation"
# Use --nomock to do the real thing
#$release_infra_clone/push-ci-build.sh --nomock ${federation_flag-}
$release_infra_clone/push-ci-build.sh ${federation_flag-}
else
./build/push-ci-build.sh
fi

sha256sum _output/release-tars/kubernetes*.tar.gz

0 comments on commit ae18034

Please sign in to comment.