From 3b66fb07fa765ab0067cf8fb227182af35be9c94 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 06:55:31 -0800 Subject: [PATCH 01/19] tests and releases --- .github/workflows/release.yml | 2 +- helm-chart/eoapi/CHANGELOG.md | 5 ++++ helm-chart/eoapi/Chart.yaml | 4 +-- helm-chart/eoapi/templates/_helpers.tpl | 25 ++++++++++++++++--- .../tests/autoscaling_feedback_alb_tests.yaml | 24 ++++++++++++++++++ .../tests/autoscaling_feedback_gce_tests.yaml | 24 ++++++++++++++++++ helm-chart/eoapi/tests/hpa_tests.yaml | 7 +++--- 7 files changed, 81 insertions(+), 10 deletions(-) create mode 100644 helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml create mode 100644 helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d31dc212..205f0156 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -7,7 +7,7 @@ on: jobs: release: - if: github.actor == 'ranchodeluxe' || github.actor == 'gcorradini' + if: github.actor == 'ranchodeluxe' || github.actor == 'gcorradini' || github.actor == 'sunu' runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 diff --git a/helm-chart/eoapi/CHANGELOG.md b/helm-chart/eoapi/CHANGELOG.md index a1cffc41..219d160a 100644 --- a/helm-chart/eoapi/CHANGELOG.md +++ b/helm-chart/eoapi/CHANGELOG.md @@ -1,5 +1,10 @@ version numbers below correspond to helm chart `appVersion`: see `./helm-chart/eoapi/Chart.yaml` --- +### 0.2.10 (2023-11-22) + +* give `ingress.className == "nginx"` the ability pass hosts and tls information +* more tests to give user feedback about the above functionality if the wrong `ingress.className` was given + ### 0.2.9 (2023-10-25) * removed `providerContext` and any support for minikube from the templates so this is a breaking change diff --git a/helm-chart/eoapi/Chart.yaml b/helm-chart/eoapi/Chart.yaml index 6b17a024..17a54423 100644 --- a/helm-chart/eoapi/Chart.yaml +++ b/helm-chart/eoapi/Chart.yaml @@ -17,10 +17,10 @@ kubeVersion: ">=1.23.0-0" # This is the chart version. This version number should be incremented each time you make changes # to the chart and its templates, including the app version. # Versions are expected to follow Semantic Versioning (https://semver.org/) -version: "0.1.11" +version: "0.1.12" # This is the version number of the application being deployed. This version number should be # incremented each time you make changes to the application. Versions are not expected to # follow Semantic Versioning. They should reflect the version the application is using. # It is recommended to use it with quotes. -appVersion: "0.2.9" +appVersion: "0.2.10" diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index 8d4dd98e..084e3e3f 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -78,8 +78,25 @@ values.schema.json doesn't play nice combined value checks so we use this helper function to check autoscaling rules */}} {{- define "eoapi.validateAutoscaleRules" -}} -{{- if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") (or (.Values.raster.autoscaling.enabled) (.Values.stac.autoscaling.enabled) (.Values.vector.autoscaling.enabled)) }} -{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's soley an nginx metric" }} -{{- end }} -{{- end -}} +{{- if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") }} + {{/* "requestRate" cannot be enabled for any service if not "nginx" so give feedback and fail */}} + {{- if (or + (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "requestRate")) + (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "requestRate")) + (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "requestRate")) + ) }} + {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's solely an nginx metric" }} + {{- end }} + + {{/* "host" has to be empty if not "nginx" so give feedback and fail */}} + {{- if .Values.ingress.host }} + {{- fail "When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time" }} + {{- end }} + + {{/* "tls" cannot be enabled if not "nginx" so give feedback and fail */}} + {{- if .Values.ingress.tls.enabled }} + {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time" }} + {{- end }} +{{- end }} {{/* if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") /*}} +{{- end -}} {{/* define */}} diff --git a/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml b/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml new file mode 100644 index 00000000..36b62248 --- /dev/null +++ b/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml @@ -0,0 +1,24 @@ +suite: autoscaling feedback when className is alb +templates: + - templates/services/ingress-alb.yaml +tests: + - it: "fail for ingress.host" + set: + raster.enabled: false + stac.enabled: false + vector.enabled: false + ingress.className: "alb" + ingress.host: "abcd.eoapi.com" + asserts: + - failedTemplate: + errorMessage: When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time + - it: "fail for ingress.tls.enabled" + set: + raster.enabled: false + stac.enabled: false + vector.enabled: false + ingress.className: "alb" + ingress.tls.enabled: true + asserts: + - failedTemplate: + errorMessage: When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time \ No newline at end of file diff --git a/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml b/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml new file mode 100644 index 00000000..02e05c49 --- /dev/null +++ b/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml @@ -0,0 +1,24 @@ +suite: autoscaling feedback when className is gce +templates: + - templates/services/ingress-gce.yaml +tests: + - it: "fail for ingress.host" + set: + raster.enabled: false + stac.enabled: false + vector.enabled: false + ingress.className: "gce" + ingress.host: "abcd.eoapi.com" + asserts: + - failedTemplate: + errorMessage: When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time + - it: "fail for ingress.tls.enabled" + set: + raster.enabled: false + stac.enabled: false + vector.enabled: false + ingress.className: "gce" + ingress.tls.enabled: true + asserts: + - failedTemplate: + errorMessage: When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time \ No newline at end of file diff --git a/helm-chart/eoapi/tests/hpa_tests.yaml b/helm-chart/eoapi/tests/hpa_tests.yaml index 3fa342d0..1f0ca6d1 100644 --- a/helm-chart/eoapi/tests/hpa_tests.yaml +++ b/helm-chart/eoapi/tests/hpa_tests.yaml @@ -1,8 +1,8 @@ -suite: service defaults deployment +suite: autoscaling feedback when className is not nginx templates: - templates/services/hpa.yaml tests: - - it: "vector hpa fail state" + - it: "vector hpa fail for requestRate" set: raster.enabled: false stac.enabled: false @@ -11,4 +11,5 @@ tests: vector.autoscaling.enabled: true asserts: - failedTemplate: - errorMessage: When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's soley an nginx metric + errorMessage: When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's solely an nginx metric + From 9487985b0e9e5e2ea3e91975d1aa09df8204dff5 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 06:57:45 -0800 Subject: [PATCH 02/19] try this --- helm-chart/eoapi/templates/_helpers.tpl | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index 084e3e3f..c500d96f 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -80,11 +80,7 @@ so we use this helper function to check autoscaling rules {{- define "eoapi.validateAutoscaleRules" -}} {{- if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") }} {{/* "requestRate" cannot be enabled for any service if not "nginx" so give feedback and fail */}} - {{- if (or - (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "requestRate")) - (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "requestRate")) - (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "requestRate")) - ) }} + {{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "requestRate")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "requestRate")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "requestRate")) ) }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's solely an nginx metric" }} {{- end }} From 6536d7a3b58bc8f3407cb98819f7da0c3968d5b9 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 06:58:56 -0800 Subject: [PATCH 03/19] more --- helm-chart/eoapi/templates/_helpers.tpl | 3 --- 1 file changed, 3 deletions(-) diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index c500d96f..fd4025f3 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -79,17 +79,14 @@ so we use this helper function to check autoscaling rules */}} {{- define "eoapi.validateAutoscaleRules" -}} {{- if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") }} - {{/* "requestRate" cannot be enabled for any service if not "nginx" so give feedback and fail */}} {{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "requestRate")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "requestRate")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "requestRate")) ) }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's solely an nginx metric" }} {{- end }} - {{/* "host" has to be empty if not "nginx" so give feedback and fail */}} {{- if .Values.ingress.host }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time" }} {{- end }} - {{/* "tls" cannot be enabled if not "nginx" so give feedback and fail */}} {{- if .Values.ingress.tls.enabled }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time" }} {{- end }} From 2a1a9156669771484690132b8befc6b3119ad817 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:00:27 -0800 Subject: [PATCH 04/19] whoops --- helm-chart/eoapi/templates/_helpers.tpl | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index fd4025f3..c8da6833 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -79,17 +79,18 @@ so we use this helper function to check autoscaling rules */}} {{- define "eoapi.validateAutoscaleRules" -}} {{- if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") }} - {{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "requestRate")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "requestRate")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "requestRate")) ) }} - {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's solely an nginx metric" }} - {{- end }} - - {{- if .Values.ingress.host }} - {{- fail "When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time" }} - {{- end }} - - {{- if .Values.ingress.tls.enabled }} - {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time" }} - {{- end }} +{{/* "requestRate" cannot be enabled for any service if not "nginx" so give feedback and fail */}} +{{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "requestRate")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "requestRate")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "requestRate")) ) }} +{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's solely an nginx metric" }} +{{- end }} +{{/* "host" has to be empty if not "nginx" so give feedback and fail */}} +{{- if .Values.ingress.host }} +{{- fail "When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time" }} +{{- end }} +{{/* "tls" cannot be enabled if not "nginx" so give feedback and fail */}} +{{- if .Values.ingress.tls.enabled }} +{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time" }} +{{- end }} {{- end }} {{/* if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") /*}} {{- end -}} {{/* define */}} From 2cfe95b1bda1bf6127f022f9b883d0c63ff37c3a Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:03:23 -0800 Subject: [PATCH 05/19] again --- helm-chart/eoapi/templates/_helpers.tpl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index c8da6833..6375a4c7 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -91,6 +91,6 @@ so we use this helper function to check autoscaling rules {{- if .Values.ingress.tls.enabled }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time" }} {{- end }} -{{- end }} {{/* if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") /*}} -{{- end -}} {{/* define */}} +{{- end }} # if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") +{{- end -}} # define From 542c4db5f50b4b417427820095719c923115e7d7 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:09:35 -0800 Subject: [PATCH 06/19] have to enable service --- helm-chart/eoapi/templates/_helpers.tpl | 4 ++++ .../eoapi/tests/autoscaling_feedback_alb_tests.yaml | 8 ++++++-- .../eoapi/tests/autoscaling_feedback_gce_tests.yaml | 8 ++++++-- 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index 6375a4c7..f7eb6c53 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -83,6 +83,10 @@ so we use this helper function to check autoscaling rules {{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "requestRate")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "requestRate")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "requestRate")) ) }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's solely an nginx metric" }} {{- end }} +{{/* "both" cannot be enabled for any service if not "nginx" so give feedback and fail */}} +{{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "both")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "both")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "both")) ) }} +{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'both' at this time b/c "requestRate' is solely an nginx metric" }} +{{- end }} {{/* "host" has to be empty if not "nginx" so give feedback and fail */}} {{- if .Values.ingress.host }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time" }} diff --git a/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml b/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml index 36b62248..fb47d225 100644 --- a/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml +++ b/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml @@ -6,7 +6,9 @@ tests: set: raster.enabled: false stac.enabled: false - vector.enabled: false + vector.enabled: true + vector.autoscaling.enabled: true + vector.autoscaling.type: "cpu" ingress.className: "alb" ingress.host: "abcd.eoapi.com" asserts: @@ -16,7 +18,9 @@ tests: set: raster.enabled: false stac.enabled: false - vector.enabled: false + vector.enabled: true + vector.autoscaling.enabled: true + vector.autoscaling.type: "cpu" ingress.className: "alb" ingress.tls.enabled: true asserts: diff --git a/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml b/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml index 02e05c49..bb8e664c 100644 --- a/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml +++ b/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml @@ -6,7 +6,9 @@ tests: set: raster.enabled: false stac.enabled: false - vector.enabled: false + vector.enabled: true + vector.autoscaling.enabled: true + vector.autoscaling.type: "cpu" ingress.className: "gce" ingress.host: "abcd.eoapi.com" asserts: @@ -16,7 +18,9 @@ tests: set: raster.enabled: false stac.enabled: false - vector.enabled: false + vector.enabled: true + vector.autoscaling.enabled: true + vector.autoscaling.type: "cpu" ingress.className: "gce" ingress.tls.enabled: true asserts: From dc1c964bd1d9fb73c1e24c47fb8a450f63b77539 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:15:06 -0800 Subject: [PATCH 07/19] moar --- helm-chart/eoapi/templates/_helpers.tpl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index f7eb6c53..37c60c42 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -95,6 +95,6 @@ so we use this helper function to check autoscaling rules {{- if .Values.ingress.tls.enabled }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time" }} {{- end }} -{{- end }} # if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") -{{- end -}} # define +{{- end }} +{{- end -}} From a60b120d51d3654557aaf87d5b6c454eaa168d21 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:20:40 -0800 Subject: [PATCH 08/19] add testing=true --- helm-chart/eoapi/test-helm-values.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/helm-chart/eoapi/test-helm-values.yaml b/helm-chart/eoapi/test-helm-values.yaml index 71ee356e..0e04c193 100644 --- a/helm-chart/eoapi/test-helm-values.yaml +++ b/helm-chart/eoapi/test-helm-values.yaml @@ -1,6 +1,8 @@ # this file is used with `helm-tests` job in CI providerContext: "aws" +testing: true + ingress: enabled: true From 4c7668bdab102d5c37c90297eb62a7df17fbf076 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:26:04 -0800 Subject: [PATCH 09/19] try --release-name --- .github/workflows/helm-tests.yml | 2 +- helm-chart/eoapi/test-helm-values.yaml | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/helm-tests.yml b/.github/workflows/helm-tests.yml index 5b993a66..657270b0 100644 --- a/.github/workflows/helm-tests.yml +++ b/.github/workflows/helm-tests.yml @@ -24,7 +24,7 @@ jobs: github-token: ${{ secrets.GITHUB_TOKEN }} - run: | cd helm-chart - helm unittest eoapi -f 'tests/*.yaml' -v eoapi/test-helm-values.yaml + helm unittest eoapi --release-name "eoapi" -f 'tests/*.yaml' -v eoapi/test-helm-values.yaml unit-tests: if: github.event.pull_request.head.repo.full_name == github.repository permissions: diff --git a/helm-chart/eoapi/test-helm-values.yaml b/helm-chart/eoapi/test-helm-values.yaml index 0e04c193..71ee356e 100644 --- a/helm-chart/eoapi/test-helm-values.yaml +++ b/helm-chart/eoapi/test-helm-values.yaml @@ -1,8 +1,6 @@ # this file is used with `helm-tests` job in CI providerContext: "aws" -testing: true - ingress: enabled: true From 466f2010d0022326567ec3d0f811df0fb237d9c5 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:27:17 -0800 Subject: [PATCH 10/19] move location --- .github/workflows/helm-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/helm-tests.yml b/.github/workflows/helm-tests.yml index 657270b0..80016ac9 100644 --- a/.github/workflows/helm-tests.yml +++ b/.github/workflows/helm-tests.yml @@ -24,7 +24,7 @@ jobs: github-token: ${{ secrets.GITHUB_TOKEN }} - run: | cd helm-chart - helm unittest eoapi --release-name "eoapi" -f 'tests/*.yaml' -v eoapi/test-helm-values.yaml + helm --release-name "eoapi" unittest eoapi -f 'tests/*.yaml' -v eoapi/test-helm-values.yaml unit-tests: if: github.event.pull_request.head.repo.full_name == github.repository permissions: From 3e897dce11917acdfacb24f7eeb3b95f6190d658 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:30:00 -0800 Subject: [PATCH 11/19] wat --- .github/workflows/helm-tests.yml | 2 +- helm-chart/eoapi/templates/_helpers.tpl | 8 -------- 2 files changed, 1 insertion(+), 9 deletions(-) diff --git a/.github/workflows/helm-tests.yml b/.github/workflows/helm-tests.yml index 80016ac9..5b993a66 100644 --- a/.github/workflows/helm-tests.yml +++ b/.github/workflows/helm-tests.yml @@ -24,7 +24,7 @@ jobs: github-token: ${{ secrets.GITHUB_TOKEN }} - run: | cd helm-chart - helm --release-name "eoapi" unittest eoapi -f 'tests/*.yaml' -v eoapi/test-helm-values.yaml + helm unittest eoapi -f 'tests/*.yaml' -v eoapi/test-helm-values.yaml unit-tests: if: github.event.pull_request.head.repo.full_name == github.repository permissions: diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index 37c60c42..7915810d 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -87,14 +87,6 @@ so we use this helper function to check autoscaling rules {{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "both")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "both")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "both")) ) }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'both' at this time b/c "requestRate' is solely an nginx metric" }} {{- end }} -{{/* "host" has to be empty if not "nginx" so give feedback and fail */}} -{{- if .Values.ingress.host }} -{{- fail "When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time" }} -{{- end }} -{{/* "tls" cannot be enabled if not "nginx" so give feedback and fail */}} -{{- if .Values.ingress.tls.enabled }} -{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time" }} -{{- end }} {{- end }} {{- end -}} From 959649e6e3a579bc3f4cb4f14fa066fbbd72ee6c Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:36:48 -0800 Subject: [PATCH 12/19] isolate --- helm-chart/eoapi/templates/_helpers.tpl | 8 ++++++ .../tests/autoscaling_feedback_alb_tests.yaml | 28 ------------------- .../tests/autoscaling_feedback_gce_tests.yaml | 28 ------------------- 3 files changed, 8 insertions(+), 56 deletions(-) delete mode 100644 helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml delete mode 100644 helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index 7915810d..37c60c42 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -87,6 +87,14 @@ so we use this helper function to check autoscaling rules {{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "both")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "both")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "both")) ) }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'both' at this time b/c "requestRate' is solely an nginx metric" }} {{- end }} +{{/* "host" has to be empty if not "nginx" so give feedback and fail */}} +{{- if .Values.ingress.host }} +{{- fail "When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time" }} +{{- end }} +{{/* "tls" cannot be enabled if not "nginx" so give feedback and fail */}} +{{- if .Values.ingress.tls.enabled }} +{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time" }} +{{- end }} {{- end }} {{- end -}} diff --git a/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml b/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml deleted file mode 100644 index fb47d225..00000000 --- a/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml +++ /dev/null @@ -1,28 +0,0 @@ -suite: autoscaling feedback when className is alb -templates: - - templates/services/ingress-alb.yaml -tests: - - it: "fail for ingress.host" - set: - raster.enabled: false - stac.enabled: false - vector.enabled: true - vector.autoscaling.enabled: true - vector.autoscaling.type: "cpu" - ingress.className: "alb" - ingress.host: "abcd.eoapi.com" - asserts: - - failedTemplate: - errorMessage: When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time - - it: "fail for ingress.tls.enabled" - set: - raster.enabled: false - stac.enabled: false - vector.enabled: true - vector.autoscaling.enabled: true - vector.autoscaling.type: "cpu" - ingress.className: "alb" - ingress.tls.enabled: true - asserts: - - failedTemplate: - errorMessage: When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time \ No newline at end of file diff --git a/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml b/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml deleted file mode 100644 index bb8e664c..00000000 --- a/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml +++ /dev/null @@ -1,28 +0,0 @@ -suite: autoscaling feedback when className is gce -templates: - - templates/services/ingress-gce.yaml -tests: - - it: "fail for ingress.host" - set: - raster.enabled: false - stac.enabled: false - vector.enabled: true - vector.autoscaling.enabled: true - vector.autoscaling.type: "cpu" - ingress.className: "gce" - ingress.host: "abcd.eoapi.com" - asserts: - - failedTemplate: - errorMessage: When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time - - it: "fail for ingress.tls.enabled" - set: - raster.enabled: false - stac.enabled: false - vector.enabled: true - vector.autoscaling.enabled: true - vector.autoscaling.type: "cpu" - ingress.className: "gce" - ingress.tls.enabled: true - asserts: - - failedTemplate: - errorMessage: When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time \ No newline at end of file From ec7200a67bed9f75a0170c2bf78139b3ea588237 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:37:53 -0800 Subject: [PATCH 13/19] isolate2 --- helm-chart/eoapi/templates/_helpers.tpl | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index 37c60c42..8d4dd98e 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -78,23 +78,8 @@ values.schema.json doesn't play nice combined value checks so we use this helper function to check autoscaling rules */}} {{- define "eoapi.validateAutoscaleRules" -}} -{{- if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") }} -{{/* "requestRate" cannot be enabled for any service if not "nginx" so give feedback and fail */}} -{{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "requestRate")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "requestRate")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "requestRate")) ) }} -{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's solely an nginx metric" }} -{{- end }} -{{/* "both" cannot be enabled for any service if not "nginx" so give feedback and fail */}} -{{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "both")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "both")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "both")) ) }} -{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'both' at this time b/c "requestRate' is solely an nginx metric" }} -{{- end }} -{{/* "host" has to be empty if not "nginx" so give feedback and fail */}} -{{- if .Values.ingress.host }} -{{- fail "When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time" }} -{{- end }} -{{/* "tls" cannot be enabled if not "nginx" so give feedback and fail */}} -{{- if .Values.ingress.tls.enabled }} -{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time" }} -{{- end }} +{{- if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") (or (.Values.raster.autoscaling.enabled) (.Values.stac.autoscaling.enabled) (.Values.vector.autoscaling.enabled)) }} +{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's soley an nginx metric" }} {{- end }} {{- end -}} From f8b3e9ca7cc13e6c460553054495793416735f8a Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:39:04 -0800 Subject: [PATCH 14/19] solely change --- helm-chart/eoapi/templates/_helpers.tpl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index 8d4dd98e..970629f2 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -79,7 +79,7 @@ so we use this helper function to check autoscaling rules */}} {{- define "eoapi.validateAutoscaleRules" -}} {{- if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") (or (.Values.raster.autoscaling.enabled) (.Values.stac.autoscaling.enabled) (.Values.vector.autoscaling.enabled)) }} -{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's soley an nginx metric" }} +{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's solely an nginx metric" }} {{- end }} {{- end -}} From 0d4708952823e698114b4e122ce8be5e2a4f2e51 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:43:49 -0800 Subject: [PATCH 15/19] slowly put back1 --- helm-chart/eoapi/templates/_helpers.tpl | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index 970629f2..7915810d 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -78,8 +78,15 @@ values.schema.json doesn't play nice combined value checks so we use this helper function to check autoscaling rules */}} {{- define "eoapi.validateAutoscaleRules" -}} -{{- if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") (or (.Values.raster.autoscaling.enabled) (.Values.stac.autoscaling.enabled) (.Values.vector.autoscaling.enabled)) }} +{{- if and .Values.ingress.enabled (ne .Values.ingress.className "nginx") }} +{{/* "requestRate" cannot be enabled for any service if not "nginx" so give feedback and fail */}} +{{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "requestRate")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "requestRate")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "requestRate")) ) }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's solely an nginx metric" }} {{- end }} +{{/* "both" cannot be enabled for any service if not "nginx" so give feedback and fail */}} +{{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "both")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "both")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "both")) ) }} +{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'both' at this time b/c "requestRate' is solely an nginx metric" }} +{{- end }} +{{- end }} {{- end -}} From cad0a80b64697b4b0824f1112a8612b989595f34 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:45:46 -0800 Subject: [PATCH 16/19] whittle --- helm-chart/eoapi/templates/_helpers.tpl | 5 ----- 1 file changed, 5 deletions(-) diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index 7915810d..99de60bd 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -83,10 +83,5 @@ so we use this helper function to check autoscaling rules {{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "requestRate")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "requestRate")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "requestRate")) ) }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's solely an nginx metric" }} {{- end }} -{{/* "both" cannot be enabled for any service if not "nginx" so give feedback and fail */}} -{{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "both")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "both")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "both")) ) }} -{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'both' at this time b/c "requestRate' is solely an nginx metric" }} -{{- end }} {{- end }} {{- end -}} - From 979ebe5eb55be36df7438b6e54f6ebf739b90a42 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:47:08 -0800 Subject: [PATCH 17/19] got it --- helm-chart/eoapi/templates/_helpers.tpl | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index 99de60bd..e22b55be 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -83,5 +83,9 @@ so we use this helper function to check autoscaling rules {{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "requestRate")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "requestRate")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "requestRate")) ) }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'requestRate' at this time b/c it's solely an nginx metric" }} {{- end }} +{{/* "both" cannot be enabled for any service if not "nginx" so give feedback and fail */}} +{{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "both")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "both")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "both")) ) }} +{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'both' at this time b/c 'requestRate' is solely an nginx metric" }} +{{- end }} {{- end }} {{- end -}} From 1adfa574dd6735e1348cbf004449e885294a597c Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:49:27 -0800 Subject: [PATCH 18/19] add everything back in --- helm-chart/eoapi/templates/_helpers.tpl | 8 ++++++ .../tests/autoscaling_feedback_alb_tests.yaml | 28 +++++++++++++++++++ .../tests/autoscaling_feedback_gce_tests.yaml | 28 +++++++++++++++++++ 3 files changed, 64 insertions(+) create mode 100644 helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml create mode 100644 helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index e22b55be..40462c03 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -87,5 +87,13 @@ so we use this helper function to check autoscaling rules {{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "both")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "both")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "both")) ) }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'both' at this time b/c 'requestRate' is solely an nginx metric" }} {{- end }} +{{/* "host" has to be empty if not "nginx" so give feedback and fail */}} +{{- if .Values.ingress.host }} +{{- fail "When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time" }} +{{- end }} +{{/* "tls" cannot be enabled if not "nginx" so give feedback and fail */}} +{{- if .Values.ingress.tls.enabled }} +{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time" }} +{{- end }} {{- end }} {{- end -}} diff --git a/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml b/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml new file mode 100644 index 00000000..fb47d225 --- /dev/null +++ b/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml @@ -0,0 +1,28 @@ +suite: autoscaling feedback when className is alb +templates: + - templates/services/ingress-alb.yaml +tests: + - it: "fail for ingress.host" + set: + raster.enabled: false + stac.enabled: false + vector.enabled: true + vector.autoscaling.enabled: true + vector.autoscaling.type: "cpu" + ingress.className: "alb" + ingress.host: "abcd.eoapi.com" + asserts: + - failedTemplate: + errorMessage: When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time + - it: "fail for ingress.tls.enabled" + set: + raster.enabled: false + stac.enabled: false + vector.enabled: true + vector.autoscaling.enabled: true + vector.autoscaling.type: "cpu" + ingress.className: "alb" + ingress.tls.enabled: true + asserts: + - failedTemplate: + errorMessage: When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time \ No newline at end of file diff --git a/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml b/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml new file mode 100644 index 00000000..606fed29 --- /dev/null +++ b/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml @@ -0,0 +1,28 @@ +suite: autoscaling feedback when className is gce +templates: + - templates/services/ingress-gce.yaml +tests: + - it: "fail for ingress.host" + set: + raster.enabled: false + stac.enabled: false + vector.enabled: true + vector.autoscaling.enabled: true + vector.autoscaling.type: "cpu" + ingress.className: "gce" + ingress.host: "abcd.eoapi.com" + asserts: + - failedTemplate: + errorMessage: When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time + - it: "fail for ingress.tls.enabled" + set: + raster.enabled: false + stac.enabled: false + vector.enabled: true + vector.autoscaling.enabled: true + vector.autoscaling.type: "cpu" + ingress.className: "gce" + ingress.tls.enabled: true + asserts: + - failedTemplate: + errorMessage: When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time From e658a379d95dea835bd045c8c17259dad80c5fe6 Mon Sep 17 00:00:00 2001 From: ranchodeluxe Date: Wed, 22 Nov 2023 07:52:05 -0800 Subject: [PATCH 19/19] better tests --- helm-chart/eoapi/templates/_helpers.tpl | 8 ------ .../tests/autoscaling_feedback_alb_tests.yaml | 28 ------------------- .../tests/autoscaling_feedback_gce_tests.yaml | 28 ------------------- 3 files changed, 64 deletions(-) delete mode 100644 helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml delete mode 100644 helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml diff --git a/helm-chart/eoapi/templates/_helpers.tpl b/helm-chart/eoapi/templates/_helpers.tpl index 40462c03..e22b55be 100644 --- a/helm-chart/eoapi/templates/_helpers.tpl +++ b/helm-chart/eoapi/templates/_helpers.tpl @@ -87,13 +87,5 @@ so we use this helper function to check autoscaling rules {{- if (or (and .Values.raster.autoscaling.enabled (eq .Values.raster.autoscaling.type "both")) (and .Values.stac.autoscaling.enabled (eq .Values.stac.autoscaling.type "both")) (and .Values.vector.autoscaling.enabled (eq .Values.vector.autoscaling.type "both")) ) }} {{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable autoscaling by 'both' at this time b/c 'requestRate' is solely an nginx metric" }} {{- end }} -{{/* "host" has to be empty if not "nginx" so give feedback and fail */}} -{{- if .Values.ingress.host }} -{{- fail "When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time" }} -{{- end }} -{{/* "tls" cannot be enabled if not "nginx" so give feedback and fail */}} -{{- if .Values.ingress.tls.enabled }} -{{- fail "When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time" }} -{{- end }} {{- end }} {{- end -}} diff --git a/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml b/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml deleted file mode 100644 index fb47d225..00000000 --- a/helm-chart/eoapi/tests/autoscaling_feedback_alb_tests.yaml +++ /dev/null @@ -1,28 +0,0 @@ -suite: autoscaling feedback when className is alb -templates: - - templates/services/ingress-alb.yaml -tests: - - it: "fail for ingress.host" - set: - raster.enabled: false - stac.enabled: false - vector.enabled: true - vector.autoscaling.enabled: true - vector.autoscaling.type: "cpu" - ingress.className: "alb" - ingress.host: "abcd.eoapi.com" - asserts: - - failedTemplate: - errorMessage: When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time - - it: "fail for ingress.tls.enabled" - set: - raster.enabled: false - stac.enabled: false - vector.enabled: true - vector.autoscaling.enabled: true - vector.autoscaling.type: "cpu" - ingress.className: "alb" - ingress.tls.enabled: true - asserts: - - failedTemplate: - errorMessage: When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time \ No newline at end of file diff --git a/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml b/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml deleted file mode 100644 index 606fed29..00000000 --- a/helm-chart/eoapi/tests/autoscaling_feedback_gce_tests.yaml +++ /dev/null @@ -1,28 +0,0 @@ -suite: autoscaling feedback when className is gce -templates: - - templates/services/ingress-gce.yaml -tests: - - it: "fail for ingress.host" - set: - raster.enabled: false - stac.enabled: false - vector.enabled: true - vector.autoscaling.enabled: true - vector.autoscaling.type: "cpu" - ingress.className: "gce" - ingress.host: "abcd.eoapi.com" - asserts: - - failedTemplate: - errorMessage: When using an 'ingress.className' other than 'nginx' you cannot provision a 'host' at this time - - it: "fail for ingress.tls.enabled" - set: - raster.enabled: false - stac.enabled: false - vector.enabled: true - vector.autoscaling.enabled: true - vector.autoscaling.type: "cpu" - ingress.className: "gce" - ingress.tls.enabled: true - asserts: - - failedTemplate: - errorMessage: When using an 'ingress.className' other than 'nginx' you cannot enable 'tls' at this time