Skip to content

Commit 9c7197b

Browse files
authored
Merge pull request #17003 from spowelljr/fixGopogh
CI: Fix gopogh not installed & missing DB_BACKEND
2 parents 1f0e7c5 + 2199679 commit 9c7197b

File tree

4 files changed

+30
-7
lines changed

4 files changed

+30
-7
lines changed

hack/jenkins/common.sh

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -428,10 +428,7 @@ if ! type "jq" > /dev/null; then
428428
fi
429429

430430
echo ">> Installing gopogh"
431-
go install github.com/medyagh/gopogh/cmd/gopogh@v0.19.0
432-
# temporary: remove the old install of gopogh as it's taking priority over our current install, preventing updating
433-
sudo rm -f /usr/local/bin/gopogh
434-
431+
./installers/check_install_gopogh.sh
435432

436433
echo ">> Running gopogh"
437434
if test -f "${HTML_OUT}"; then
@@ -442,7 +439,7 @@ touch "${HTML_OUT}"
442439
touch "${SUMMARY_OUT}"
443440
if [ "$EXTERNAL" != "yes" ] && [ "$MINIKUBE_LOCATION" = "master" ]
444441
then
445-
gopogh -in "${JSON_OUT}" -out_html "${HTML_OUT}" -out_summary "${SUMMARY_OUT}" -name "${JOB_NAME}" -pr "${MINIKUBE_LOCATION}" -repo github.com/kubernetes/minikube/ -details "${COMMIT}:$(date +%Y-%m-%d):${ROOT_JOB_ID}" -db_host "${GOPOGH_DB_HOST}" -db_path "${GOPOGH_DB_PATH}" -use_cloudsql -use_iam_auth || true
442+
gopogh -in "${JSON_OUT}" -out_html "${HTML_OUT}" -out_summary "${SUMMARY_OUT}" -name "${JOB_NAME}" -pr "${MINIKUBE_LOCATION}" -repo github.com/kubernetes/minikube/ -details "${COMMIT}:$(date +%Y-%m-%d):${ROOT_JOB_ID}" -db_backend "${GOPOGH_DB_BACKEND}" -db_host "${GOPOGH_DB_HOST}" -db_path "${GOPOGH_DB_PATH}" -use_cloudsql -use_iam_auth || true
446443
else
447444
gopogh -in "${JSON_OUT}" -out_html "${HTML_OUT}" -out_summary "${SUMMARY_OUT}" -name "${JOB_NAME}" -pr "${MINIKUBE_LOCATION}" -repo github.com/kubernetes/minikube/ -details "${COMMIT}:$(date +%Y-%m-%d):${ROOT_JOB_ID}" || true
448445
fi
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
#!/bin/bash
2+
3+
# Copyright 2023 The Kubernetes Authors All rights reserved.
4+
#
5+
# Licensed under the Apache License, Version 2.0 (the "License");
6+
# you may not use this file except in compliance with the License.
7+
# You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing, software
12+
# distributed under the License is distributed on an "AS IS" BASIS,
13+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
# See the License for the specific language governing permissions and
15+
# limitations under the License.
16+
17+
set -eux -o pipefail
18+
19+
# installing golang so we can go install gopogh
20+
./installers/check_install_golang.sh "/usr/local" || true
21+
22+
# temporary: remove the old install of gopogh as it's taking priority over our current install, preventing updating
23+
sudo rm -f /usr/local/bin/gopogh
24+
25+
go install github.com/medyagh/gopogh/cmd/gopogh@v0.19.0

hack/jenkins/upload_integration_report.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,5 +50,6 @@ gsutil -qm cp "${SUMMARY_OUT}" "gs://${JOB_GCS_BUCKET}_summary.json" || true
5050

5151
if [ "$MINIKUBE_LOCATION" = "master" ]
5252
then
53-
gopogh -in "${JSON_OUT}" -name "${JOB_NAME}" -pr "${MINIKUBE_LOCATION}" -repo github.com/kubernetes/minikube/ -details "${COMMIT}:$(date +%Y-%m-%d):${ROOT_JOB_ID}" -db_host "${GOPOGH_DB_HOST}" -db_path "${GOPOGH_DB_PATH}" -use_cloudsql -use_iam_auth || true
53+
./installers/check_install_gopogh.sh
54+
gopogh -in "${JSON_OUT}" -name "${JOB_NAME}" -pr "${MINIKUBE_LOCATION}" -repo github.com/kubernetes/minikube/ -details "${COMMIT}:$(date +%Y-%m-%d):${ROOT_JOB_ID}" -db_backend "${GOPOGH_DB_BACKEND}" -db_host "${GOPOGH_DB_HOST}" -db_path "${GOPOGH_DB_PATH}" -use_cloudsql -use_iam_auth || true
5455
fi

hack/update/gopogh_version/update_gopogh_version.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ var (
5252
`github.com/medyagh/gopogh/cmd/gopogh@.*`: `github.com/medyagh/gopogh/cmd/gopogh@{{.StableVersion}}`,
5353
},
5454
},
55-
"hack/jenkins/common.sh": {
55+
"hack/jenkins/installers/check_install_gopogh.sh": {
5656
Replace: map[string]string{
5757
`github.com/medyagh/gopogh/cmd/gopogh@.*`: `github.com/medyagh/gopogh/cmd/gopogh@{{.StableVersion}}`,
5858
},

0 commit comments

Comments
 (0)