mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-29 22:46:12 +00:00
Use upload-to-gcs.sh everywhere
This commit is contained in:
parent
f83a6f1665
commit
62b3587b62
@ -207,8 +207,9 @@ fi
|
|||||||
cd kubernetes
|
cd kubernetes
|
||||||
|
|
||||||
# Upload build start time and k8s version to GCS, but not on PR Jenkins.
|
# Upload build start time and k8s version to GCS, but not on PR Jenkins.
|
||||||
|
# On PR Jenkins this is done before the build.
|
||||||
if [[ ! "${JOB_NAME}" =~ -pull- ]]; then
|
if [[ ! "${JOB_NAME}" =~ -pull- ]]; then
|
||||||
bash <(curl -fsS --retry 3 "https://raw.githubusercontent.com/kubernetes/kubernetes/master/hack/jenkins/upload-started.sh")
|
JENKINS_BUILD_STARTED=true bash <(curl -fsS --retry 3 "https://raw.githubusercontent.com/kubernetes/kubernetes/master/hack/jenkins/upload-to-gcs.sh")
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Have cmd/e2e run by goe2e.sh generate JUnit report in ${WORKSPACE}/junit*.xml
|
# Have cmd/e2e run by goe2e.sh generate JUnit report in ${WORKSPACE}/junit*.xml
|
||||||
|
@ -14,40 +14,33 @@
|
|||||||
- postbuildscript:
|
- postbuildscript:
|
||||||
builders:
|
builders:
|
||||||
- shell: |
|
- shell: |
|
||||||
curl -fsS --retry 3 "https://raw.githubusercontent.com/kubernetes/kubernetes/master/hack/jenkins/upload-finished.sh" > upload-finished.sh
|
mkdir -p _tmp
|
||||||
chmod +x upload-finished.sh
|
curl -fsS --retry 3 "https://raw.githubusercontent.com/kubernetes/kubernetes/master/hack/jenkins/upload-to-gcs.sh" > ./_tmp/upload-to-gcs.sh
|
||||||
|
chmod +x ./_tmp/upload-to-gcs.sh
|
||||||
- conditional-step:
|
- conditional-step:
|
||||||
condition-kind: current-status
|
condition-kind: current-status
|
||||||
condition-worst: SUCCESS
|
condition-worst: SUCCESS
|
||||||
condition-best: SUCCESS
|
condition-best: SUCCESS
|
||||||
steps:
|
steps:
|
||||||
- shell: './upload-finished.sh SUCCESS'
|
- shell: 'JENKINS_BUILD_FINISHED=SUCCESS ./_tmp/upload-to-gcs.sh'
|
||||||
- conditional-step:
|
- conditional-step:
|
||||||
condition-kind: current-status
|
condition-kind: current-status
|
||||||
condition-worst: UNSTABLE
|
condition-worst: UNSTABLE
|
||||||
condition-best: UNSTABLE
|
condition-best: UNSTABLE
|
||||||
steps:
|
steps:
|
||||||
- shell: './upload-finished.sh UNSTABLE'
|
- shell: 'JENKINS_BUILD_FINISHED=UNSTABLE ./_tmp/upload-to-gcs.sh'
|
||||||
- conditional-step:
|
- conditional-step:
|
||||||
condition-kind: current-status
|
condition-kind: current-status
|
||||||
condition-worst: FAILURE
|
condition-worst: FAILURE
|
||||||
condition-best: FAILURE
|
condition-best: FAILURE
|
||||||
steps:
|
steps:
|
||||||
- shell: './upload-finished.sh FAILURE'
|
- shell: 'JENKINS_BUILD_FINISHED=FAILURE ./_tmp/upload-to-gcs.sh'
|
||||||
- conditional-step:
|
- conditional-step:
|
||||||
condition-kind: current-status
|
condition-kind: current-status
|
||||||
condition-worst: ABORTED
|
condition-worst: ABORTED
|
||||||
condition-best: ABORTED
|
condition-best: ABORTED
|
||||||
steps:
|
steps:
|
||||||
- shell: './upload-finished.sh ABORTED'
|
- shell: 'JENKINS_BUILD_FINISHED=ABORTED ./_tmp/upload-to-gcs.sh'
|
||||||
# Use our script for build artifacts, since it's more flexible.
|
|
||||||
# Run last since it updates latest-build.txt.
|
|
||||||
- shell: |
|
|
||||||
if [[ -x ./hack/jenkins/upload-to-gcs.sh ]]; then
|
|
||||||
./hack/jenkins/upload-to-gcs.sh
|
|
||||||
else
|
|
||||||
curl -fsS --retry 3 "https://raw.githubusercontent.com/kubernetes/kubernetes/master/hack/jenkins/upload-to-gcs.sh" | bash -
|
|
||||||
fi
|
|
||||||
script-only-if-succeeded: False
|
script-only-if-succeeded: False
|
||||||
script-only-if-failed: False
|
script-only-if-failed: False
|
||||||
# Use the plugin for the build log, since it isn't available on Jenkins slaves.
|
# Use the plugin for the build log, since it isn't available on Jenkins slaves.
|
||||||
|
@ -5,7 +5,7 @@
|
|||||||
logrotate:
|
logrotate:
|
||||||
numToKeep: 200
|
numToKeep: 200
|
||||||
builders:
|
builders:
|
||||||
- shell: 'bash <(curl -fsS --retry 3 "https://raw.githubusercontent.com/kubernetes/kubernetes/master/hack/jenkins/upload-started.sh")'
|
- shell: 'JENKINS_BUILD_STARTED=true bash <(curl -fsS --retry 3 "https://raw.githubusercontent.com/kubernetes/kubernetes/master/hack/jenkins/upload-to-gcs.sh")'
|
||||||
- shell: |
|
- shell: |
|
||||||
timeout -k {kill-timeout}m 30m ./hack/jenkins/build.sh && rc=$? || rc=$?
|
timeout -k {kill-timeout}m 30m ./hack/jenkins/build.sh && rc=$? || rc=$?
|
||||||
{report-rc}
|
{report-rc}
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
numToKeep: 200
|
numToKeep: 200
|
||||||
node: unittest
|
node: unittest
|
||||||
builders:
|
builders:
|
||||||
- shell: 'bash <(curl -fsS --retry 3 "https://raw.githubusercontent.com/kubernetes/kubernetes/master/hack/jenkins/upload-started.sh")'
|
- shell: 'JENKINS_BUILD_STARTED=true bash <(curl -fsS --retry 3 "https://raw.githubusercontent.com/kubernetes/kubernetes/master/hack/jenkins/upload-to-gcs.sh")'
|
||||||
- shell: |
|
- shell: |
|
||||||
export KUBE_FORCE_VERIFY_CHECKS='y'
|
export KUBE_FORCE_VERIFY_CHECKS='y'
|
||||||
export KUBE_VERIFY_GIT_BRANCH='{branch}'
|
export KUBE_VERIFY_GIT_BRANCH='{branch}'
|
||||||
|
Loading…
Reference in New Issue
Block a user