diff --git a/apis/core/v1alpha1/flagsourceconfiguration_types.go b/apis/core/v1alpha1/flagsourceconfiguration_types.go index f01a51e09..6e7dde2e2 100644 --- a/apis/core/v1alpha1/flagsourceconfiguration_types.go +++ b/apis/core/v1alpha1/flagsourceconfiguration_types.go @@ -49,7 +49,7 @@ const ( defaultEvaluator string = "json" defaultImage string = "ghcr.io/open-feature/flagd" // renovate: datasource=github-tags depName=open-feature/flagd/flagd - defaultTag string = "v0.5.4" + defaultTag string = "v0.6.2" defaultLogFormat string = "json" defaultProbesEnabled bool = true SyncProviderKubernetes SyncProviderType = "kubernetes" diff --git a/chart/open-feature-operator/README.md b/chart/open-feature-operator/README.md index 5a756a71a..d7f4270fc 100644 --- a/chart/open-feature-operator/README.md +++ b/chart/open-feature-operator/README.md @@ -98,7 +98,7 @@ The command removes all the Kubernetes components associated with the chart and | `sidecarConfiguration.metricsPort` | Sets the value of the `XXX_METRICS_PORT` environment variable for the injected sidecar. | `8014` | | `sidecarConfiguration.socketPath` | Sets the value of the `XXX_SOCKET_PATH` environment variable for the injected sidecar. | `""` | | `sidecarConfiguration.image.repository` | Sets the image for the injected sidecar. | `ghcr.io/open-feature/flagd` | -| `sidecarConfiguration.image.tag` | Sets the version tag for the injected sidecar. | `v0.5.4` | +| `sidecarConfiguration.image.tag` | Sets the version tag for the injected sidecar. | `v0.6.2` | | `sidecarConfiguration.providerArgs` | Used to append arguments to the sidecar startup command. This value is a comma separated string of key values separated by '=', e.g. `key=value,key2=value2` results in the appending of `--sync-provider-args key=value --sync-provider-args key2=value2`. | `""` | | `sidecarConfiguration.envVarPrefix` | Sets the prefix for all environment variables set in the injected sidecar. | `FLAGD` | | `sidecarConfiguration.defaultSyncProvider` | Sets the value of the `XXX_SYNC_PROVIDER` environment variable for the injected sidecar container. There are 3 valid sync providers: `kubernetes`, `filepath` and `http`. | `kubernetes` | @@ -114,7 +114,7 @@ The command removes all the Kubernetes components associated with the chart and | `flagdProxyConfiguration.port` | Sets the port to expose the sync API on. | `8015` | | `flagdProxyConfiguration.metricsPort` | Sets the port to expose the metrics API on. | `8016` | | `flagdProxyConfiguration.image.repository` | Sets the image for the flagd-proxy deployment. | `ghcr.io/open-feature/flagd-proxy` | -| `flagdProxyConfiguration.image.tag` | Sets the tag for the flagd-proxy deployment. | `v0.2.4` | +| `flagdProxyConfiguration.image.tag` | Sets the tag for the flagd-proxy deployment. | `v0.2.7` | | `flagdProxyConfiguration.debugLogging` | Controls the addition of the `--debug` flag to the container startup arguments. | `false` | ### Operator resource configuration diff --git a/chart/open-feature-operator/values.yaml b/chart/open-feature-operator/values.yaml index 958a2cbcd..ecac2c88c 100644 --- a/chart/open-feature-operator/values.yaml +++ b/chart/open-feature-operator/values.yaml @@ -16,7 +16,7 @@ sidecarConfiguration: ## @param sidecarConfiguration.image.repository Sets the image for the injected sidecar. repository: "ghcr.io/open-feature/flagd" ## @param sidecarConfiguration.image.tag Sets the version tag for the injected sidecar. - tag: v0.5.4 + tag: v0.6.2 ## @param sidecarConfiguration.providerArgs Used to append arguments to the sidecar startup command. This value is a comma separated string of key values separated by '=', e.g. `key=value,key2=value2` results in the appending of `--sync-provider-args key=value --sync-provider-args key2=value2`. providerArgs: "" ## @param sidecarConfiguration.envVarPrefix Sets the prefix for all environment variables set in the injected sidecar. @@ -42,7 +42,7 @@ flagdProxyConfiguration: ## @param flagdProxyConfiguration.image.repository Sets the image for the flagd-proxy deployment. repository: "ghcr.io/open-feature/flagd-proxy" ## @param flagdProxyConfiguration.image.tag Sets the tag for the flagd-proxy deployment. - tag: v0.2.4 + tag: v0.2.7 ## @param flagdProxyConfiguration.debugLogging Controls the addition of the `--debug` flag to the container startup arguments. debugLogging: false diff --git a/controllers/common/flagd-proxy.go b/controllers/common/flagd-proxy.go index 7f8f8caab..44896beea 100644 --- a/controllers/common/flagd-proxy.go +++ b/controllers/common/flagd-proxy.go @@ -22,7 +22,7 @@ const ( FlagdProxyServiceAccountName = "open-feature-operator-flagd-proxy" FlagdProxyServiceName = "flagd-proxy-svc" // renovate: datasource=github-tags depName=open-feature/flagd/flagd-proxy - DefaultFlagdProxyTag = "v0.2.2" + DefaultFlagdProxyTag = "v0.2.7" DefaultFlagdProxyImage = "ghcr.io/open-feature/flagd-proxy" DefaultFlagdProxyPort = 8015 DefaultFlagdProxyMetricsPort = 8016 diff --git a/test/e2e/flag-evaluation.sh b/test/e2e/flag-evaluation.sh index 2867f84ef..a58f7f484 100755 --- a/test/e2e/flag-evaluation.sh +++ b/test/e2e/flag-evaluation.sh @@ -1,7 +1,7 @@ #!/bin/bash FLAG_KEY="$1" -EXPECTED_RESPONSE="$2" +EXPECTED_RESPONSE_CONTAIN="$2" # attempt up to 5 times MAX_ATTEMPTS=5 @@ -23,12 +23,12 @@ do RESPONSE=$(curl -s -X POST "localhost:30000/schema.v1.Service/ResolveBoolean" -d "{\"flagKey\":\"$FLAG_KEY\",\"context\":{}}" -H "Content-Type: application/json") RESPONSE="${RESPONSE//[[:space:]]/}" # strip whitespace from response - if [ "$RESPONSE" == "$EXPECTED_RESPONSE" ] + if [[ "$RESPONSE" == *"$EXPECTED_RESPONSE_CONTAIN"* ]] then exit 0 fi - echo "Expected response for flag $FLAG_KEY: $EXPECTED_RESPONSE" + echo "Expected response for flag $FLAG_KEY to contain: EXPECTED_RESPONSE_CONTAIN" echo "Got response for flag $FLAG_KEY: $RESPONSE" echo "Retrying in ${RETRY_INTERVAL} seconds" sleep "${RETRY_INTERVAL}" diff --git a/test/e2e/kuttl/assets/manifests.yaml b/test/e2e/kuttl/assets/manifests.yaml index 442ee0518..d785741bc 100644 --- a/test/e2e/kuttl/assets/manifests.yaml +++ b/test/e2e/kuttl/assets/manifests.yaml @@ -97,16 +97,16 @@ spec: - /bin/sh - -ec - | - EXPECTED_RESPONSE='{"value":true,"reason":"STATIC","variant":"on"}' + EXPECTED_RESPONSE_CONTAIN='"value":true,"reason":"STATIC","variant":"on"' RESPONSE=$(curl -s -X POST "open-feature-e2e-test-service:30000/schema.v1.Service/ResolveBoolean" -d '{"flagKey":"simple-flag","context":{}}' -H "Content-Type: application/json") RESPONSE="${RESPONSE//[[:space:]]/}" # strip whitespace from response - if [ "$RESPONSE" == "$EXPECTED_RESPONSE" ] + if [[ "$RESPONSE" == *"$EXPECTED_RESPONSE_CONTAIN"* ]] then exit 0 fi - echo "Expected response: $EXPECTED_RESPONSE" + echo "Expected response to contain: $EXPECTED_RESPONSE_CONTAIN" echo "Got response: $RESPONSE" exit 1 restartPolicy: OnFailure diff --git a/test/e2e/kuttl/fsconfig-file-sync/00-install.yaml b/test/e2e/kuttl/fsconfig-file-sync/00-install.yaml index c26dc2e84..652effb0e 100644 --- a/test/e2e/kuttl/fsconfig-file-sync/00-install.yaml +++ b/test/e2e/kuttl/fsconfig-file-sync/00-install.yaml @@ -8,7 +8,7 @@ spec: evaluator: json defaultSyncProvider: filepath # renovate: datasource=github-tags depName=open-feature/flagd/flagd - tag: v0.5.4 + tag: v0.6.2 sources: - source: end-to-end-test provider: filepath diff --git a/test/e2e/kuttl/fsconfig-file-sync/01-assert.yaml b/test/e2e/kuttl/fsconfig-file-sync/01-assert.yaml index b7b0879a5..f5aa99276 100644 --- a/test/e2e/kuttl/fsconfig-file-sync/01-assert.yaml +++ b/test/e2e/kuttl/fsconfig-file-sync/01-assert.yaml @@ -13,4 +13,4 @@ spec: - name: open-feature-e2e-test image: nginx:stable-alpine - name: flagd # this part verifies flagd injection happened - image: ghcr.io/open-feature/flagd:v0.5.4 + image: ghcr.io/open-feature/flagd:v0.6.2 diff --git a/test/e2e/kuttl/fsconfig-flagd-proxy-sync/00-install.yaml b/test/e2e/kuttl/fsconfig-flagd-proxy-sync/00-install.yaml index c5799e573..a03bdb3c8 100644 --- a/test/e2e/kuttl/fsconfig-flagd-proxy-sync/00-install.yaml +++ b/test/e2e/kuttl/fsconfig-flagd-proxy-sync/00-install.yaml @@ -8,7 +8,7 @@ spec: evaluator: json defaultSyncProvider: flagd-proxy # renovate: datasource=github-tags depName=open-feature/flagd/flagd - tag: v0.5.4 + tag: v0.6.2 sources: - source: end-to-end-test provider: flagd-proxy diff --git a/test/e2e/kuttl/fsconfig-flagd-proxy-sync/01-assert.yaml b/test/e2e/kuttl/fsconfig-flagd-proxy-sync/01-assert.yaml index b7b0879a5..f5aa99276 100644 --- a/test/e2e/kuttl/fsconfig-flagd-proxy-sync/01-assert.yaml +++ b/test/e2e/kuttl/fsconfig-flagd-proxy-sync/01-assert.yaml @@ -13,4 +13,4 @@ spec: - name: open-feature-e2e-test image: nginx:stable-alpine - name: flagd # this part verifies flagd injection happened - image: ghcr.io/open-feature/flagd:v0.5.4 + image: ghcr.io/open-feature/flagd:v0.6.2 diff --git a/test/e2e/kuttl/fsconfig-k8s-sync/00-install.yaml b/test/e2e/kuttl/fsconfig-k8s-sync/00-install.yaml index d38c1dc73..c3ae3d436 100644 --- a/test/e2e/kuttl/fsconfig-k8s-sync/00-install.yaml +++ b/test/e2e/kuttl/fsconfig-k8s-sync/00-install.yaml @@ -8,7 +8,7 @@ spec: evaluator: json defaultSyncProvider: kubernetes # renovate: datasource=github-tags depName=open-feature/flagd/flagd - tag: v0.5.4 + tag: v0.6.2 sources: - source: end-to-end-test provider: kubernetes diff --git a/test/e2e/kuttl/fsconfig-k8s-sync/01-assert.yaml b/test/e2e/kuttl/fsconfig-k8s-sync/01-assert.yaml index 6894663c6..149bbe864 100644 --- a/test/e2e/kuttl/fsconfig-k8s-sync/01-assert.yaml +++ b/test/e2e/kuttl/fsconfig-k8s-sync/01-assert.yaml @@ -14,4 +14,4 @@ spec: - name: open-feature-e2e-test image: nginx:stable-alpine - name: flagd # this part verifies flagd injection happened - image: ghcr.io/open-feature/flagd:v0.5.4 + image: ghcr.io/open-feature/flagd:v0.6.2 diff --git a/test/e2e/kuttl/inject-flagd/00-install.yaml b/test/e2e/kuttl/inject-flagd/00-install.yaml index ce7fbb714..87095d939 100644 --- a/test/e2e/kuttl/inject-flagd/00-install.yaml +++ b/test/e2e/kuttl/inject-flagd/00-install.yaml @@ -108,16 +108,16 @@ spec: - /bin/sh - -ec - | - EXPECTED_RESPONSE='{"value":true,"reason":"STATIC","variant":"on"}' + EXPECTED_RESPONSE_CONTAIN='"value":true,"reason":"STATIC","variant":"on"' RESPONSE=$(curl -s -X POST "open-feature-e2e-test-service:30000/schema.v1.Service/ResolveBoolean" -d '{"flagKey":"simple-flag","context":{}}' -H "Content-Type: application/json") RESPONSE="${RESPONSE//[[:space:]]/}" # strip whitespace from response - if [ "$RESPONSE" == "$EXPECTED_RESPONSE" ] + if [[ "$RESPONSE" == *"$EXPECTED_RESPONSE_CONTAIN"* ]] then exit 0 fi - echo "Expected response: $EXPECTED_RESPONSE" + echo "Expected response to contain: $EXPECTED_RESPONSE_CONTAIN" echo "Got response: $RESPONSE" exit 1 restartPolicy: OnFailure diff --git a/test/e2e/kuttl/inject-flagd/01-assert.yaml b/test/e2e/kuttl/inject-flagd/01-assert.yaml index 3147b017c..3bb0a4045 100644 --- a/test/e2e/kuttl/inject-flagd/01-assert.yaml +++ b/test/e2e/kuttl/inject-flagd/01-assert.yaml @@ -15,4 +15,4 @@ spec: - name: open-feature-e2e-test image: nginx:stable-alpine - name: flagd # this part verifies flagd injection happened - image: ghcr.io/open-feature/flagd:v0.5.4 + image: ghcr.io/open-feature/flagd:v0.6.2 diff --git a/test/e2e/tests/001.flagd-response.sh b/test/e2e/tests/001.flagd-response.sh index ec3b6def9..996cfe4d5 100755 --- a/test/e2e/tests/001.flagd-response.sh +++ b/test/e2e/tests/001.flagd-response.sh @@ -3,10 +3,10 @@ FAILURE=0 flagKeys=('simple-flag' 'simple-flag-filepath' 'simple-flag-filepath2') -expectedFlagResponses=('{"value":true,"reason":"STATIC","variant":"on"}' '{"value":true,"reason":"STATIC","variant":"on"}' '{"value":true,"reason":"STATIC","variant":"on"}') +expectedResponseContain=('value":true,"reason":"STATIC","variant":"on"' '"value":true,"reason":"STATIC","variant":"on"' '"value":true,"reason":"STATIC","variant":"on"') for i in "${!flagKeys[@]}"; do - ./"$(dirname "${BASH_SOURCE[0]}")"/../flag-evaluation.sh "${flagKeys[$i]}" "${expectedFlagResponses[$i]}" + ./"$(dirname "${BASH_SOURCE[0]}")"/../flag-evaluation.sh "${flagKeys[$i]}" "${expectedResponseContain[$i]}" EXIT_CODE=$? if [ $EXIT_CODE -ne 0 ]; then