From 8d97fa1fee5a754ec8aa73e0cd8034e9ba388cfc Mon Sep 17 00:00:00 2001 From: Keith Suderman Date: Wed, 10 Jul 2024 10:27:30 -0400 Subject: [PATCH 1/3] Check that the appVersion matches version returned by /api/version --- .github/workflows/test.yaml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index 324e7ae7..d7f156ea 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -64,3 +64,21 @@ jobs: - name: Print workflow handler log run: bash -c "kubectl logs -n galaxy $(kubectl -n galaxy get pods | grep -o '[^ ]*galaxy-workflow[^ ]*')" if: always() + - name: Print service info + run: kubectl get svc -n galaxy + if: always() + - name: Print nginx service info + run: kubectl describe svc -n galaxy galaxy-nginx + if: always() + - name: Check appVersion + if: always() + run: | + appVersion=$(cat galaxy/Chart.yaml | grep ^appVersion: | awk '{print $2}' | tr -d '"') + address=$(kubectl get svc -n galaxy galaxy-nginx -o jsonpath="http://{.spec.clusterIP}:{.spec.ports[0].port}/galaxy/api/version") + echo "Address is $address" + apiVersion=$(curl $address | jq -r '"\(.version_major).\(.version_minor)"') + echo "appVersion: $appVersion" + echo "apiVersion: $apiVersion" + if [ "$appVersion" != "$apiVersion" ]; then + exit 1 + fi From a9f1e3ac6174c821a53d877b3493dea70462d6e0 Mon Sep 17 00:00:00 2001 From: Keith Suderman Date: Wed, 10 Jul 2024 11:43:48 -0400 Subject: [PATCH 2/3] Update appVersion in the Chart.yaml --- galaxy/Chart.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/galaxy/Chart.yaml b/galaxy/Chart.yaml index bac329c0..762af1b4 100644 --- a/galaxy/Chart.yaml +++ b/galaxy/Chart.yaml @@ -2,7 +2,7 @@ apiVersion: v2 name: galaxy type: application version: 5.14.3 -appVersion: "24.0.2" +appVersion: "24.1.1" description: Chart for Galaxy, an open, web-based platform for accessible, reproducible, and transparent computational biomedical research. icon: https://galaxyproject.org/images/galaxy-logos/galaxy_project_logo_square.png dependencies: From a88a615f7eb6aa131793925681ea922c1881d1a4 Mon Sep 17 00:00:00 2001 From: Keith Suderman Date: Wed, 10 Jul 2024 14:15:18 -0400 Subject: [PATCH 3/3] Print output from kubectl as part of the appVersion test --- .github/workflows/test.yaml | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test.yaml b/.github/workflows/test.yaml index d7f156ea..db7f47f9 100644 --- a/.github/workflows/test.yaml +++ b/.github/workflows/test.yaml @@ -64,15 +64,11 @@ jobs: - name: Print workflow handler log run: bash -c "kubectl logs -n galaxy $(kubectl -n galaxy get pods | grep -o '[^ ]*galaxy-workflow[^ ]*')" if: always() - - name: Print service info - run: kubectl get svc -n galaxy - if: always() - - name: Print nginx service info - run: kubectl describe svc -n galaxy galaxy-nginx - if: always() - name: Check appVersion if: always() run: | + kubectl get svc -n galaxy + kubectl describe svc -n galaxy galaxy-nginx appVersion=$(cat galaxy/Chart.yaml | grep ^appVersion: | awk '{print $2}' | tr -d '"') address=$(kubectl get svc -n galaxy galaxy-nginx -o jsonpath="http://{.spec.clusterIP}:{.spec.ports[0].port}/galaxy/api/version") echo "Address is $address"