Skip to content

fix(redis-stack): replace the unlicensed vendored chart with an Intel chart - #50

Merged
AhmedSeemalK merged 3 commits into
intel:release-2.0.1from
vinayK34:fix/redis-intel-chart
Dec 2, 2026
Merged

AhmedSeemalK merged 3 commits into
intel:release-2.0.1from
vinayK34:fix/redis-intel-chart

Conversation

@vinayK34

@vinayK34 vinayK34 commented Dec 1, 2026 •

Copy link
Copy Markdown

Why

charts/redis-stack embedded a modified copy of the redis-stack-server chart from redis-stack/helm-redis-stack. That repository declares no license, and under Intel IP policy code without a license can't be used or redistributed. This needs to be fixed before the v2.0.1 tag.

What changed

  • Removed the copied subchart charts/redis-stack/charts/redis-stack-server/ (6 files).
  • charts/redis-stack is now a single Intel-written chart (Apache-2.0 headers), in the same style as charts/pgvector: StatefulSet, Service, Secret, NetworkPolicy.
  • It deploys the same licensed image, redis/redis-stack-server:7.4.0-v8 (RSALv2 / SSPL-1.0, Redis Stack 7.4). Redis itself is unchanged.
  • roles/redis_stack/tasks/install.yaml passes values in the chart's own layout (persistence.*, auth.*, networkPolicy.*).
  • charts/README.md: only add third-party chart code whose license allows Intel to use and redistribute it.

Kept the same, for in-place upgrades and existing clients

  • Service, StatefulSet and NetworkPolicy named redis-stack-server; StatefulSet selector app: redis-stack-server; volume claim db at /data.
  • Secret redis-stack-server-credentials with REDIS_PASSWORD and REDIS_URL.
  • Password through REDIS_ARGS --requirepass, port 6379, tolerations, security context, NetworkPolicy rules (including the Istio HBONE port 15008).

Testing

  • helm lint charts/redis-stack passes.
  • helm template with the values the role passes, compared with the previous chart: the same 4 objects, and the selector, service name, volume claim, image, pull policy, env, mounts, security context, tolerations, Secret data and NetworkPolicy rules are identical. The only differences are explicit protocol: TCP / targetPort defaults and standard app.kubernetes.io/* pod labels.
  • Also checked: a missing password fails with a clear message; auth.enabled=false renders no Secret and no REDIS_ARGS; a namespace allowlist, storage class, resources and affinity work.
  • Tested on a cluster: upgrade over an existing install and a fresh install, both passing; results in the comment below.
  • The Docker Compose option (docker/) doesn't use this chart and isn't affected.

Copilot AI balanced review requested due to automatic review settings December 1, 2026 01:47

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Legacy chart settings are ignored when the new password is supplied, potentially allowing Redis access from every namespace and causing immutable StatefulSet upgrade failures.

1 open issue
What changed in this PR

Replaces the unlicensed vendored Redis Stack subchart with an Intel-authored Apache-2.0 chart for the shared memory backend, retaining the Redis image and existing resource names.

Changes:

  • Adds standalone StatefulSet, Service, Secret, and NetworkPolicy templates.
  • Updates the Ansible role to use the chart’s new values layout.
  • Removes the vendored subchart and documents licensing requirements for third-party charts.
File Description
roles/​redis_stack/​tasks/​install.yaml Passes storage, authentication, and mesh settings through the new values layout.
charts/​redis-stack/​values.yaml Defines top-level configuration for the standalone chart.
charts/​redis-stack/​templates/​statefulset.yaml Defines the Redis workload and persistent storage.
charts/​redis-stack/​templates/​service.yaml Exposes Redis through the existing Service name.
charts/​redis-stack/​templates/​secret.yaml Defines credentials and the client connection URL.
charts/​redis-stack/​templates/​networkpolicy.yaml Defines namespace restrictions and optional mesh ingress.
charts/​redis-stack/​templates/​_helpers.tpl Centralizes resource names and labels.
charts/​redis-stack/​charts/​redis-stack-server/​values.yaml Removes vendored subchart defaults.
charts/​redis-stack/​charts/​redis-stack-server/​templates/​secret.yaml Removes the vendored Secret template.
charts/​redis-stack/​charts/​redis-stack-server/​templates/​redis-stack-server.yaml Removes vendored Service and StatefulSet templates.
charts/​redis-stack/​charts/​redis-stack-server/​templates/​networkpolicy.yaml Removes the vendored NetworkPolicy template.
charts/​redis-stack/​charts/​redis-stack-server/​templates/​_helpers.tpl Removes vendored template helpers.
charts/​redis-stack/​charts/​redis-stack-server/​Chart.yaml Removes vendored subchart metadata.
charts/​redis-stack/​Chart.yaml Adds licensing headers and increments the chart version.
charts/​README.md Clarifies dependency handling and third-party licensing requirements.

Review effort: Balanced

@@ -0,0 +1,36 @@
# Copyright (C) 2025-2026 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
{{- if .Values.networkPolicy.enabled }}

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks. Addressed in 75fc1d5.

  • Supported install path (roles/redis_stack) is not affected. The role passes the values inline on every install or upgrade (no saved values file), already in the new layout, with the same storage class and size as before, so the volume claim is unchanged. It never set allowedNamespaces or placement, so those stay at the same defaults.
  • Manual Helm installs with the old keys: rather than translating the old layout, the chart now stops with a clear error if a redis-stack-server: block is passed. The message names the new top-level keys and warns to keep persistence.* equal to the installed values. A dropped allowlist can no longer happen silently.

Tested with helm template: the role's values render the same objects as before (and pass kubeconform strict on Kubernetes 1.35); the old redis-stack-server.redis_stack_server.* keys fail with the message.

Copilot AI balanced review requested due to automatic review settings December 1, 2026 05:59

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

The Redis chart replacement lacks cluster validation, requiring human verification that an in-place upgrade preserves PVCs, data, credentials, and cross-namespace ambient-mesh connectivity.

1 open issue

Review effort: Balanced

Copilot AI balanced review requested due to automatic review settings December 1, 2026 07:18

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

The shared Redis chart replacement lacks live-cluster upgrade validation, leaving PVC data and credential retention, failed-upgrade retries, and cross-namespace ambient-mesh Service connectivity unverified.

1 open issue

Review effort: Balanced

@vinayK34
vinayK34 force-pushed the fix/redis-intel-chart branch from 2cdb194 to 87121c8 Compare December 2, 2026 04:59
@vinayK34

vinayK34 commented Dec 2, 2026

Copy link
Copy Markdown
Author

Cluster test results

Single-node Kubernetes v1.35.4 test cluster, installed with ./toolkit_manager.sh install agent-toolkit (Toolkit Manager release-2.0, Istio ambient with STRICT mTLS), Redis deployed with the previous chart (redis-0.1.0). Chart under test: this PR's charts/redis-stack (redis-0.2.0), same files as the current head.

Upgrade over the existing install (release redis, namespace redis)

Values: the release's existing values (same password, 10Gi, default StorageClass, mesh port 15008) in the new layout, as roles/redis_stack passes them.

Check Result
helm upgrade --dry-run=server ✅ accepted, no immutable-field errors
helm upgrade --install --wait ✅ revision 2 deployed in 9 s; the pod restarted once
Same data volume before and after ✅
A key and a RediSearch index written before the upgrade ✅ both still present
PING; modules ✅ PONG; search, ReJSON, timeseries, bf, redisgears_2
Password unchanged; access without password ✅ unchanged; NOAUTH
Secret keys REDIS_PASSWORD, REDIS_URL ✅
Service endpoint; NetworkPolicy ports ✅ 6379; 6379 and 15008
Client in another meshed namespace using REDIS_URL ✅ PONG and read the test key
./toolkit_manager.sh validate agent-toolkit ✅ failed=0: Redis pods OK, PING OK, RediSearch module OK

Fresh install (separate test namespace)

Check Result
helm upgrade --install --create-namespace --wait ✅ StatefulSet, Service, Secret, NetworkPolicy and PVC created
PING, RediSearch index and search, access without password ✅ PONG; 1 result; NOAUTH
REDIS_URL host ✅ redis-stack-server.<namespace>.svc.cluster.local:6379

Not covered: running roles/redis_stack itself from this branch; the test used the exact values the role passes. Test data and the test namespace were removed afterwards.

… chart

charts/redis-stack embedded a modified copy of the redis-stack-server chart from
github.com/redis-stack/helm-redis-stack. That repository declares no license, so
Intel IP policy does not allow us to use or redistribute it.

This removes the copied subchart and makes charts/redis-stack a single
Intel-written chart (Apache-2.0), in the same style as charts/pgvector. It still
deploys the same licensed image, redis/redis-stack-server:7.4.0-v8.

Kept unchanged so existing installs upgrade in place and clients keep working:
- Service, StatefulSet and NetworkPolicy name redis-stack-server
- StatefulSet selector app: redis-stack-server and volume claim db at /data
- Secret redis-stack-server-credentials with REDIS_PASSWORD and REDIS_URL
- password passed with REDIS_ARGS --requirepass, port 6379, tolerations,
  security context, NetworkPolicy rules (incl. the Istio HBONE port)

The values layout is now the chart's own (persistence.*, auth.*, networkPolicy.*
at the top level); roles/redis_stack passes them in that form. Rendered with the
role's values, the objects match the previous chart field for field, apart from
explicit protocol/targetPort defaults and standard app.kubernetes.io labels.
A values file written for the old vendored sub-chart (redis-stack-server.
redis_stack_server.*) would otherwise be ignored silently on upgrade: a namespace
allowlist would be dropped (Redis open to every namespace) and storage overrides
would no longer apply, so the immutable volume claim could differ. Stop with a
message that names the new top-level keys instead.

The redis_stack role passes the new layout and is not affected.
The previous chart set metadata.namespace on the Secret, Service and
NetworkPolicy. Set it on all four objects (StatefulSet included), so the
manifests stay in the release namespace even when they are rendered with
helm template and applied with kubectl. Installs through the redis_stack role
were not affected: Helm already places namespace-less objects in the release
namespace.

@AhmedSeemalK AhmedSeemalK left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@AhmedSeemalK
AhmedSeemalK merged commit dee0d31 into intel:release-2.0.1 Dec 2, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants