Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion charts/plane-enterprise/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ description: Meet Plane. An Enterprise software development tool to manage issue

type: application

version: 2.2.5
version: 2.3.0
appVersion: "2.5.0"

home: https://plane.so/
Expand Down
51 changes: 51 additions & 0 deletions charts/plane-enterprise/templates/NOTES.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
{{- if .Values.podIdentity.enabled }}
EKS Pod Identity (out-of-band) configuration

This chart configures the Kubernetes `ServiceAccount` name as:
{{ printf "%s-srv-account" .Release.Name }}

1. Ensure the Pod Identity agent addon is installed:
eksctl create addon --cluster {{ default "<CLUSTER_NAME>" .Values.podIdentity.clusterName }} --name eks-pod-identity-agent

2. Create the Pod Identity association:
eksctl create podidentityassociation \
--cluster {{ default "<CLUSTER_NAME>" .Values.podIdentity.clusterName }} \
--namespace {{ default .Release.Namespace .Values.podIdentity.namespace }} \
--service-account-name {{ default (printf "%s-srv-account" .Release.Name) .Values.podIdentity.serviceAccountName }} \
--role-arn {{ default "<ROLE_ARN>" .Values.podIdentity.roleArn }}

Alternative (AWS CLI):
aws eks create-pod-identity-association \
--cluster-name {{ default "<CLUSTER_NAME>" .Values.podIdentity.clusterName }} \
--namespace {{ default .Release.Namespace .Values.podIdentity.namespace }} \
--service-account {{ default (printf "%s-srv-account" .Release.Name) .Values.podIdentity.serviceAccountName }} \
--role-arn {{ default "<ROLE_ARN>" .Values.podIdentity.roleArn }}

Important:
- Pod Identity associations are managed outside of Helm/Kubernetes manifests (for example via `eksctl` / AWS APIs).
- Pod Identity is not configured purely by ServiceAccount annotations in this setup.
{{- else }}
IRSA configuration (IAM Roles for Service Accounts)

To enable AWS permissions for this chart's ServiceAccount:
- set `irsa.roleArn`, or
- set `serviceAccount.annotations` / `irsa.annotations` with `eks.amazonaws.com/role-arn`.

This chart's ServiceAccount name is:
{{ printf "%s-srv-account" .Release.Name }}
{{- end }}

---
## Secret ARN driven env wiring

This chart conditionally renders AWS Secrets Manager ARN-related env vars (for example `AMAZONMQ_SECRET_ARN`, `ELASTICACHE_SECRET_ARN`, `RDS_SECRET_ARN`) and the corresponding `*_KEY` mappings only when the ARN values (and the required key-name values) are provided.

To verify what will be rendered for your current values, run:

```sh
helm template <RELEASE_NAME> ./charts/plane-enterprise \
--namespace <NAMESPACE> \
-f <YOUR_VALUES_YAML> | \
rg -n "AMAZONMQ_SECRET_ARN|ELASTICACHE_SECRET_ARN|RDS_SECRET_ARN|RABBITMQ_(USER_KEY|PASSWORD_KEY)|RDS_DB_(HOST_KEY|NAME_KEY|PASSWORD_KEY|PORT_KEY|USERNAME_KEY)|FOLLOWER_RDS_DB_(HOST_KEY|NAME_KEY|PASSWORD_KEY|PORT_KEY|USERNAME_KEY)|MODEL_CUSTOM_LLM_API_KEY"
```

39 changes: 39 additions & 0 deletions charts/plane-enterprise/templates/config-secrets/app-env.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,17 @@ stringData:
LIVE_SERVER_SECRET_KEY: {{ .Values.env.live_server_secret_key | default "htbqvBJAgpm9bzvf3r4urJer0ENReatceh" | quote }}
PI_INTERNAL_SECRET: {{ .Values.env.pi_envs.internal_secret | default "tyfvfqvBJAgpm9bzvf3r4urJer0Ehfdubk" | quote }}

# AWS Secrets Manager ARNs (consumed by workloads via envFrom plane-app-secrets)
{{- if and (not (empty .Values.env.apiSecrets.amazonmq_secret_arn)) (not (empty .Values.env.rabbitmq_user_key)) (not (empty .Values.env.rabbitmq_password_key)) }}
AMAZONMQ_SECRET_ARN: {{ .Values.env.apiSecrets.amazonmq_secret_arn | quote }}
{{- end }}
{{- if and (not (empty .Values.env.apiSecrets.elasticache_secret_arn)) (not (empty .Values.env.redis_auth_token_key)) }}
ELASTICACHE_SECRET_ARN: {{ .Values.env.apiSecrets.elasticache_secret_arn | quote }}
{{- end }}
{{- if and (not (empty .Values.env.apiSecrets.rds_secret_arn)) (not (empty .Values.env.rds_db_host_key)) (not (empty .Values.env.rds_db_name_key)) (not (empty .Values.env.rds_db_password_key)) (not (empty .Values.env.rds_db_port_key)) (not (empty .Values.env.rds_db_username_key)) }}
RDS_SECRET_ARN: {{ .Values.env.apiSecrets.rds_secret_arn | quote }}
{{- end }}

{{- if .Values.services.redis.local_setup }}
REDIS_URL: "redis://{{ .Release.Name }}-redis.{{ .Release.Namespace }}.svc.cluster.local:6379/"
{{- else }}
Expand Down Expand Up @@ -91,3 +102,31 @@ data:
{{- else}}
CORS_ALLOWED_ORIGINS: "http://{{ .Values.license.licenseDomain }},https://{{ .Values.license.licenseDomain }}"
{{- end }}

# Secret cache TTL for the credentials provider used by the app.
AWS_SECRET_CACHE_TTL: {{ .Values.env.aws_secret_cache_ttl | default "300" | quote }}

# Runner base URL used by the automation runner integration.
{{- if .Values.env.runner_base_url }}
RUNNER_BASE_URL: {{ .Values.env.runner_base_url | quote }}
{{- else }}
RUNNER_BASE_URL: "http://plane-node-runner.{{ .Release.Namespace }}.svc.cluster.local:3000"
{{- end }}
Comment on lines +109 to +114

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.

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Check if node-runner service is defined in this chart with a fixed or release-based name
rg -n "node-runner" --type yaml charts/plane-enterprise/

Repository: makeplane/helm-charts

Length of output: 224


🏁 Script executed:

# Check service definitions and deployments to understand the naming pattern
fd "service" charts/plane-enterprise/templates/ -type f | head -20

Repository: makeplane/helm-charts

Length of output: 235


🏁 Script executed:

# Look for other service URL patterns in app-env.yaml to compare naming conventions
rg -A 2 "Release.Name" charts/plane-enterprise/templates/config-secrets/app-env.yaml | head -40

Repository: makeplane/helm-charts

Length of output: 1917


🏁 Script executed:

# Check if there are any node-runner related deployments or services
fd . charts/plane-enterprise/templates/ -type f -exec rg -l "runner" {} \;

Repository: makeplane/helm-charts

Length of output: 235


🏁 Script executed:

# Check values.yaml for runner configuration and service definitions
head -100 charts/plane-enterprise/values.yaml | grep -A 10 -B 10 "runner\|Runner" || rg -C 5 "runner.*service\|node.runner" charts/plane-enterprise/values.yaml | head -50

Repository: makeplane/helm-charts

Length of output: 47


🏁 Script executed:

# Check if node-runner has deployment templates in this chart
find charts/plane-enterprise/templates -type f -name "*runner*" -o -type f -name "*node*"

Repository: makeplane/helm-charts

Length of output: 47


🏁 Script executed:

# Look for Chart.yaml or dependencies that might reference node-runner
rg -i "dependencies|node-runner" charts/plane-enterprise/Chart.yaml

Repository: makeplane/helm-charts

Length of output: 47


🏁 Script executed:

# Check if there's a separate node-runner chart
ls -la charts/ | grep -i runner

Repository: makeplane/helm-charts

Length of output: 47


🏁 Script executed:

# Check the values.yaml file for runner-related configuration
grep -n "runner" charts/plane-enterprise/values.yaml

Repository: makeplane/helm-charts

Length of output: 158


🏁 Script executed:

# Look at the complete context of RUNNER_BASE_URL in app-env.yaml
sed -n '100,120p' charts/plane-enterprise/templates/config-secrets/app-env.yaml

Repository: makeplane/helm-charts

Length of output: 1126


🏁 Script executed:

# Check if there are any other references to "plane-node-runner" in the entire chart
rg "plane-node-runner" charts/plane-enterprise/

Repository: makeplane/helm-charts

Length of output: 220


🏁 Script executed:

# Check if there's any documentation about plane-node-runner in README or docs
find charts/plane-enterprise -name "*.md" -o -name "*.txt" -o -name "*.rst" | xargs grep -l "node-runner\|runner" 2>/dev/null

Repository: makeplane/helm-charts

Length of output: 49


🏁 Script executed:

# Check the git history to see if there's context about this naming choice
git log --oneline -n 30 -- charts/plane-enterprise/templates/config-secrets/app-env.yaml 2>/dev/null | head -10

Repository: makeplane/helm-charts

Length of output: 108


🏁 Script executed:

# Look at the entire values.yaml section about services to understand the architecture
sed -n '480,510p' charts/plane-enterprise/values.yaml

Repository: makeplane/helm-charts

Length of output: 850


Hardcoded service name doesn't follow release-name convention.

The default RUNNER_BASE_URL uses plane-node-runner instead of {{ .Release.Name }}-node-runner, which is inconsistent with every other internal service URL in this template (redis, pgdb, rabbitmq, monitor, live). If the node-runner service is deployed as part of this chart, this will cause connection failures when users deploy with a custom release name.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@charts/plane-enterprise/templates/config-secrets/app-env.yaml` around lines
109 - 114, The default RUNNER_BASE_URL fallback currently hardcodes the service
as "plane-node-runner", causing mismatches with release-scoped services; update
the template logic that sets RUNNER_BASE_URL (the block using
.Values.env.runner_base_url) so the fallback host follows the same release-name
convention as other services by using .Release.Name (e.g., "{{ .Release.Name
}}-node-runner") combined with .Release.Namespace and port 3000, preserving the
existing conditional that prefers .Values.env.runner_base_url when provided.


# AWS Secrets Manager key mappings (key names, not the secret ARNs).
{{- if and (not (empty .Values.env.apiSecrets.elasticache_secret_arn)) (not (empty .Values.env.redis_auth_token_key)) }}
REDIS_AUTH_TOKEN_KEY: {{ .Values.env.redis_auth_token_key | quote }}
{{- end }}

{{- if and (not (empty .Values.env.apiSecrets.amazonmq_secret_arn)) (not (empty .Values.env.rabbitmq_user_key)) (not (empty .Values.env.rabbitmq_password_key)) }}
RABBITMQ_USER_KEY: {{ .Values.env.rabbitmq_user_key | quote }}
RABBITMQ_PASSWORD_KEY: {{ .Values.env.rabbitmq_password_key | quote }}
{{- end }}

{{- if and (not (empty .Values.env.apiSecrets.rds_secret_arn)) (not (empty .Values.env.rds_db_host_key)) (not (empty .Values.env.rds_db_name_key)) (not (empty .Values.env.rds_db_password_key)) (not (empty .Values.env.rds_db_port_key)) (not (empty .Values.env.rds_db_username_key)) }}
RDS_DB_HOST_KEY: {{ .Values.env.rds_db_host_key | quote }}
RDS_DB_NAME_KEY: {{ .Values.env.rds_db_name_key | quote }}
RDS_DB_PASSWORD_KEY: {{ .Values.env.rds_db_password_key | quote }}
RDS_DB_PORT_KEY: {{ .Values.env.rds_db_port_key | quote }}
RDS_DB_USERNAME_KEY: {{ .Values.env.rds_db_username_key | quote }}
{{- end }}
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ metadata:
name: {{ .Release.Name }}-live-secrets
stringData:
LIVE_SERVER_SECRET_KEY: {{ .Values.env.live_server_secret_key | default "htbqvBJAgpm9bzvf3r4urJer0ENReatceh" | quote }}
# Used by PI workloads to resolve ElastiCache credentials.
# This value is rendered into `live-secrets` (not `pi-api-vars`/`pi-api-secrets`).
{{- if and (not (empty .Values.env.apiSecrets.elasticache_secret_arn)) (not (empty .Values.env.redis_auth_token_key)) }}
ELASTICACHE_SECRET_ARN: {{ .Values.env.apiSecrets.elasticache_secret_arn | quote }}
{{- end }}
{{- if .Values.services.redis.local_setup }}
REDIS_URL: "redis://{{ .Release.Name }}-redis.{{ .Release.Namespace }}.svc.cluster.local:6379/"
{{- else }}
Expand All @@ -26,6 +31,9 @@ data:
LIVE_SENTRY_TRACES_SAMPLE_RATE: {{ .Values.env.live_sentry_traces_sample_rate | default "" | quote }}
LIVE_BASE_PATH: "/live"

# Secret cache TTL used by the credentials provider in workloads.
AWS_SECRET_CACHE_TTL: {{ .Values.env.aws_secret_cache_ttl | default "300" | quote }}

{{- if .Values.env.external_iframely_url }}
IFRAMELY_URL: {{ .Values.env.external_iframely_url | default "" | quote }}
{{- else }}
Expand Down
46 changes: 41 additions & 5 deletions charts/plane-enterprise/templates/config-secrets/pi-api-env.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
{{ $resolvedFollowerRdsArn := default .Values.env.apiSecrets.rds_secret_arn .Values.services.pi.apiSecrets.follower_rds_secret_arn }}

{{- if and .Values.services.pi.enabled (empty .Values.external_secrets.pi_api_env_existingSecret)}}

apiVersion: v1
Expand Down Expand Up @@ -56,12 +58,22 @@ stringData:
CUSTOM_LLM_API_KEY: ""
{{- end }}

{{- if .Values.services.pi.ai_providers.embedding_model.enabled }}
BR_AWS_SECRET_ACCESS_KEY: {{ .Values.services.pi.ai_providers.embedding_model.aws_secret_access_key | default "" | quote }}
BR_AWS_SESSION_TOKEN: {{ .Values.services.pi.ai_providers.embedding_model.aws_session_token | default "" | quote }}
{{- end }}

AES_SECRET_KEY: {{ .Values.env.silo_envs.aes_secret_key | default "dsOdt7YrvxsTIFJ37pOaEVvLxN8KGBCr" | quote }}
{{- if and (not (empty $resolvedFollowerRdsArn)) (not (empty .Values.env.pi_envs.follower_rds_db_host_key)) (not (empty .Values.env.pi_envs.follower_rds_db_name_key)) (not (empty .Values.env.pi_envs.follower_rds_db_password_key)) (not (empty .Values.env.pi_envs.follower_rds_db_port_key)) (not (empty .Values.env.pi_envs.follower_rds_db_username_key)) }}
FOLLOWER_RDS_SECRET_ARN: {{ $resolvedFollowerRdsArn | quote }}
{{- end }}
{{- if and (not (empty .Values.env.apiSecrets.amazonmq_secret_arn)) (not (empty .Values.env.pi_envs.rabbitmq_user_key)) (not (empty .Values.env.pi_envs.rabbitmq_password_key)) }}
AMAZONMQ_SECRET_ARN: {{ .Values.env.apiSecrets.amazonmq_secret_arn | quote }}
{{- end }}
{{- if and (not (empty .Values.services.pi.apiSecrets.rds_secret_arn)) (not (empty .Values.env.pi_envs.rds_db_host_key)) (not (empty .Values.env.pi_envs.rds_db_name_key)) (not (empty .Values.env.pi_envs.rds_db_password_key)) (not (empty .Values.env.pi_envs.rds_db_port_key)) (not (empty .Values.env.pi_envs.rds_db_username_key)) }}
RDS_SECRET_ARN: {{ .Values.services.pi.apiSecrets.rds_secret_arn | quote }}
{{- end }}
{{- if and (not (empty .Values.services.pi.apiSecrets.model_secret_arn)) (not (empty .Values.services.pi.ai_providers.custom_llm.api_key)) }}
MODEL_SECRET_ARN: {{ .Values.services.pi.apiSecrets.model_secret_arn | quote }}
{{- end }}
{{- end }}
---

Expand Down Expand Up @@ -91,11 +103,33 @@ data:
{{- end }}

PI_INTERNAL_SECRET: {{ .Values.env.pi_envs.internal_secret | default "tyfvfqvBJAgpm9bzvf3r4urJer0Ehfdubk" | quote }}
AWS_SECRET_CACHE_TTL: {{ .Values.env.aws_secret_cache_ttl | default "300" | quote }}

FEATURE_FLAG_SERVER_BASE_URL: "http://{{ .Release.Name }}-monitor.{{ .Release.Namespace }}.svc.cluster.local:8080"
PI_BASE_PATH: "/pi"


{{- if and (not (empty .Values.env.apiSecrets.amazonmq_secret_arn)) (not (empty .Values.env.pi_envs.rabbitmq_password_key)) (not (empty .Values.env.pi_envs.rabbitmq_user_key)) }}
RABBITMQ_PASSWORD_KEY: {{ .Values.env.pi_envs.rabbitmq_password_key | quote }}
RABBITMQ_USER_KEY: {{ .Values.env.pi_envs.rabbitmq_user_key | quote }}
{{- end }}
Comment on lines +119 to +122

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.

⚠️ Potential issue | 🟠 Major

Inconsistent condition: ConfigMap uses direct value while Secret uses resolved variable.

Line 76 uses $resolvedAmazonmqSecretArn (which respects the PI-specific override), but line 119 checks only .Values.env.apiSecrets.amazonmq_secret_arn. If a user sets only the PI-specific services.pi.apiSecrets.amazonmq_secret_arn, the Secret entry AMAZONMQ_SECRET_ARN will render, but these ConfigMap key mappings won't—causing a partial and likely broken configuration.

Proposed fix to use the resolved variable consistently
-  {{- if and (not (empty .Values.env.apiSecrets.amazonmq_secret_arn)) (not (empty .Values.env.pi_envs.rabbitmq_password_key)) (not (empty .Values.env.pi_envs.rabbitmq_user_key)) }}
+  {{- if and (not (empty $resolvedAmazonmqSecretArn)) (not (empty .Values.env.pi_envs.rabbitmq_password_key)) (not (empty .Values.env.pi_envs.rabbitmq_user_key)) }}
   RABBITMQ_PASSWORD_KEY: {{ .Values.env.pi_envs.rabbitmq_password_key | quote }}
   RABBITMQ_USER_KEY: {{ .Values.env.pi_envs.rabbitmq_user_key | quote }}
   {{- end }}
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
{{- if and (not (empty .Values.env.apiSecrets.amazonmq_secret_arn)) (not (empty .Values.env.pi_envs.rabbitmq_password_key)) (not (empty .Values.env.pi_envs.rabbitmq_user_key)) }}
RABBITMQ_PASSWORD_KEY: {{ .Values.env.pi_envs.rabbitmq_password_key | quote }}
RABBITMQ_USER_KEY: {{ .Values.env.pi_envs.rabbitmq_user_key | quote }}
{{- end }}
{{- if and (not (empty $resolvedAmazonmqSecretArn)) (not (empty .Values.env.pi_envs.rabbitmq_password_key)) (not (empty .Values.env.pi_envs.rabbitmq_user_key)) }}
RABBITMQ_PASSWORD_KEY: {{ .Values.env.pi_envs.rabbitmq_password_key | quote }}
RABBITMQ_USER_KEY: {{ .Values.env.pi_envs.rabbitmq_user_key | quote }}
{{- end }}
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@charts/plane-enterprise/templates/config-secrets/pi-api-env.yaml` around
lines 119 - 122, The condition gating the RABBITMQ_* entries is inconsistent
with the ConfigMap: replace the direct check of
.Values.env.apiSecrets.amazonmq_secret_arn with the PI-resolved variable so both
use the same source of truth; specifically, update the if expression that
currently tests .Values.env.apiSecrets.amazonmq_secret_arn to test
$resolvedAmazonmqSecretArn (and keep the checks for
.Values.env.pi_envs.rabbitmq_password_key and
.Values.env.pi_envs.rabbitmq_user_key) so the Secret rendering for
AMAZONMQ_SECRET_ARN and the ConfigMap use the same resolved value.


{{- if and (not (empty .Values.services.pi.apiSecrets.rds_secret_arn)) (not (empty .Values.env.pi_envs.rds_db_host_key)) (not (empty .Values.env.pi_envs.rds_db_name_key)) (not (empty .Values.env.pi_envs.rds_db_password_key)) (not (empty .Values.env.pi_envs.rds_db_port_key)) (not (empty .Values.env.pi_envs.rds_db_username_key)) }}
RDS_DB_HOST_KEY: {{ .Values.env.pi_envs.rds_db_host_key | quote }}
RDS_DB_NAME_KEY: {{ .Values.env.pi_envs.rds_db_name_key | quote }}
RDS_DB_PASSWORD_KEY: {{ .Values.env.pi_envs.rds_db_password_key | quote }}
RDS_DB_PORT_KEY: {{ .Values.env.pi_envs.rds_db_port_key | quote }}
RDS_DB_USERNAME_KEY: {{ .Values.env.pi_envs.rds_db_username_key | quote }}
{{ end }}

{{- if and (not (empty $resolvedFollowerRdsArn)) (not (empty .Values.env.pi_envs.follower_rds_db_host_key)) (not (empty .Values.env.pi_envs.follower_rds_db_name_key)) (not (empty .Values.env.pi_envs.follower_rds_db_password_key)) (not (empty .Values.env.pi_envs.follower_rds_db_port_key)) (not (empty .Values.env.pi_envs.follower_rds_db_username_key)) }}
{{- /* Render follower DB key names only when resolved follower secret ARN exists. */ -}}
FOLLOWER_RDS_DB_HOST_KEY: {{ .Values.env.pi_envs.follower_rds_db_host_key | quote }}
FOLLOWER_RDS_DB_NAME_KEY: {{ .Values.env.pi_envs.follower_rds_db_name_key | quote }}
FOLLOWER_RDS_DB_PASSWORD_KEY: {{ .Values.env.pi_envs.follower_rds_db_password_key | quote }}
FOLLOWER_RDS_DB_PORT_KEY: {{ .Values.env.pi_envs.follower_rds_db_port_key | quote }}
FOLLOWER_RDS_DB_USERNAME_KEY: {{ .Values.env.pi_envs.follower_rds_db_username_key | quote }}
{{- end }}

{{- if eq .Values.env.pi_envs.cors_allowed_origins "*"}}
CORS_ALLOWED_ORIGINS: "*"
{{- else if .Values.env.pi_envs.cors_allowed_origins }}
Expand Down Expand Up @@ -134,12 +168,14 @@ data:
CUSTOM_LLM_AWS_REGION: ""
{{- end }}

{{- if .Values.services.pi.ai_providers.embedding_model.enabled }}
{{- if and (not (empty .Values.services.pi.apiSecrets.model_secret_arn)) (not (empty .Values.services.pi.ai_providers.custom_llm.api_key)) }}
MODEL_CUSTOM_LLM_API_KEY: {{ .Values.services.pi.ai_providers.custom_llm.api_key | quote }}
{{- end }}

EMBEDDING_MODEL: {{ .Values.services.pi.ai_providers.embedding_model.name | default "" | quote }}
OPENSEARCH_ML_MODEL_ID: {{ .Values.services.pi.ai_providers.embedding_model.model_id | default "" | quote }}
BR_AWS_ACCESS_KEY_ID: {{ .Values.services.pi.ai_providers.embedding_model.aws_access_key | default "" | quote }}
BR_AWS_REGION: {{ .Values.services.pi.ai_providers.embedding_model.aws_region | default "us-east-1" | quote }}
{{- end }}

CELERY_VECTOR_SYNC_ENABLED: {{ .Values.env.pi_envs.celery.vector_sync_enabled | ternary "1" "0" | quote }}
CELERY_VECTOR_SYNC_INTERVAL: {{ .Values.env.pi_envs.celery.vector_sync_interval | default 3 | quote }}
Expand Down
2 changes: 2 additions & 0 deletions charts/plane-enterprise/templates/config-secrets/silo.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -91,5 +91,7 @@ data:
SENTRY_ENVIRONMENT: {{ .Values.env.silo_envs.sentry_environment | default "development" | quote }}
SENTRY_TRACES_SAMPLE_RATE: {{ .Values.env.silo_envs.sentry_traces_sample_rate | default "0.1" | quote }}

AWS_SECRET_CACHE_TTL: {{ .Values.env.aws_secret_cache_ttl | default "300" | quote }}

{{- end }}
---
13 changes: 13 additions & 0 deletions charts/plane-enterprise/templates/service-account.yaml
Original file line number Diff line number Diff line change
@@ -1,9 +1,22 @@
{{- $annotations := dict -}}
{{- with .Values.serviceAccount.annotations -}}
{{- $annotations = merge $annotations . -}}
{{- end -}}
{{- with .Values.irsa.annotations -}}
{{- $annotations = merge $annotations . -}}
{{- end -}}
{{- if .Values.irsa.roleArn -}}
{{- $annotations = merge $annotations (dict "eks.amazonaws.com/role-arn" .Values.irsa.roleArn) -}}
{{- end -}}
Comment on lines +1 to +10

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.

⚠️ Potential issue | 🟡 Minor

Merge precedence may surprise users expecting irsa.roleArn to override.

Helm's merge function gives precedence to the first (leftmost) map, meaning:

  1. If serviceAccount.annotations contains eks.amazonaws.com/role-arn, it will NOT be overridden by irsa.annotations or irsa.roleArn.
  2. If irsa.annotations contains eks.amazonaws.com/role-arn, it will NOT be overridden by irsa.roleArn.

This contradicts the comment in values.yaml (line 432) stating "Additional/override IRSA annotations". Consider documenting this precedence or reversing the merge order so irsa.roleArn takes highest precedence.

♻️ Option: Reverse merge order so irsa.roleArn wins
 {{- $annotations := dict -}}
-{{- with .Values.serviceAccount.annotations -}}
-{{- $annotations = merge $annotations . -}}
-{{- end -}}
-{{- with .Values.irsa.annotations -}}
-{{- $annotations = merge $annotations . -}}
-{{- end -}}
 {{- if .Values.irsa.roleArn -}}
-{{- $annotations = merge $annotations (dict "eks.amazonaws.com/role-arn" .Values.irsa.roleArn) -}}
+{{- $annotations = merge $annotations (dict "eks.amazonaws.com/role-arn" .Values.irsa.roleArn) -}}
+{{- end -}}
+{{- with .Values.irsa.annotations -}}
+{{- $annotations = merge $annotations . -}}
+{{- end -}}
+{{- with .Values.serviceAccount.annotations -}}
+{{- $annotations = merge $annotations . -}}
 {{- end -}}

This makes irsa.roleArn highest priority, then irsa.annotations, then serviceAccount.annotations.

🧰 Tools
🪛 YAMLlint (1.38.0)

[error] 1-1: syntax error: expected the node content, but found '-'

(syntax)

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@charts/plane-enterprise/templates/service-account.yaml` around lines 1 - 10,
The merge order currently gives earlier maps precedence, so
.Values.serviceAccount.annotations or .Values.irsa.annotations can block
.Values.irsa.roleArn; fix by reversing the overlay order so IRSA wins: when
merging into $annotations ensure the overlay maps for .Values.irsa.annotations
and the role ARN dict (".Values.irsa.roleArn") are passed as the first argument
to merge (i.e., treat them as the overriding maps) or build the final
$annotations by starting from serviceAccount then overlaying irsa.annotations
then overlaying the roleArn dict so that the role ARN and irsa annotations have
highest precedence; update the merge calls referencing $annotations,
.Values.serviceAccount.annotations, .Values.irsa.annotations, and
.Values.irsa.roleArn accordingly.


apiVersion: v1
automountServiceAccountToken: true
kind: ServiceAccount
metadata:
namespace: {{ .Release.Namespace }}
name: {{ .Release.Name }}-srv-account
annotations:
{{ toYaml $annotations | nindent 4 }}
{{- if .Values.dockerRegistry.enabled }}
imagePullSecrets:
{{- if .Values.dockerRegistry.existingSecret }}
Expand Down
80 changes: 80 additions & 0 deletions charts/plane-enterprise/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -388,6 +388,14 @@ services:
aws_region: 'us-east-1'
aws_session_token: ''

apiSecrets:
# Used by PI API to look up external secrets/credentials.
# Values are expected to be base64-encoded strings (as provided by the user).
follower_rds_secret_arn: ''
model_secret_arn: ''
amazonmq_secret_arn: ''
rds_secret_arn: ''
Comment on lines +400 to +406

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.

⚠️ Potential issue | 🟡 Minor

Misleading comment: ARNs are not base64-encoded.

The comment states "Values are expected to be base64-encoded strings" but AWS Secrets Manager ARNs are plain text identifiers (e.g., arn:aws:secretsmanager:region:account-id:secret:name). This same misleading comment also appears at lines 467-468 for env.apiSecrets.

📝 Proposed fix
   apiSecrets:
-      # Used by PI API to look up external secrets/credentials.
-      # Values are expected to be base64-encoded strings (as provided by the user).
+      # Used by PI API to look up external secrets/credentials.
+      # Provide the full AWS Secrets Manager ARN.
       follower_rds_secret_arn: ''

Apply the same fix at line 467-468.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@charts/plane-enterprise/values.yaml` around lines 391 - 397, The comment for
apiSecrets incorrectly states values are base64-encoded; ARNs (e.g.,
follower_rds_secret_arn, model_secret_arn, amazonmq_secret_arn, rds_secret_arn
under apiSecrets and the duplicate comment for env.apiSecrets) are plain-text
identifiers — update the comment to reflect that these fields expect ARN strings
(or plain text secret identifiers) rather than base64-encoded values, and apply
the same correction to the duplicate comment near env.apiSecrets.


pi_beat_worker:
replicas: 1
memoryLimit: 1000Mi
Expand All @@ -412,6 +420,32 @@ services:
labels: {}
annotations: {}

serviceAccount:
# ServiceAccount annotations to apply to the chart's ServiceAccount.
# Common use-case: IRSA (IAM Roles for Service Accounts).
annotations: {}

irsa:
# When set, the chart automatically sets:
# eks.amazonaws.com/role-arn: <roleArn>
roleArn: ''
# Additional/override IRSA annotations to apply to the ServiceAccount.
annotations: {}

podIdentity:
# EKS Pod Identity is configured out-of-band (for example with `eksctl`).
# This chart only renders install-time guidance; it does not create the
# PodIdentityAssociation resource.
enabled: false
# Cluster name for the `eksctl create podidentityassociation` command.
clusterName: ''
# Namespace for the ServiceAccount (defaults to the Helm release namespace).
namespace: ''
# ServiceAccount name (defaults to `<releaseName>-srv-account`).
serviceAccountName: ''
# IAM role ARN to associate for Pod Identity.
roleArn: ''

external_secrets:
# Name of the existing Kubernetes Secret resource; see README for more details
rabbitmq_existingSecret: ''
Expand All @@ -426,6 +460,33 @@ external_secrets:
env:
storageClass: ''

# Secrets Manager credential cache TTL (seconds)
aws_secret_cache_ttl: "300"

apiSecrets:
# Shared AWS Secrets Manager ARNs used by api/live/pi workloads.
# Values are expected to be base64-encoded strings (as provided by the user).
amazonmq_secret_arn: "arn:aws:secretsmanager:us-east-1:426043895157:secret:gp/api/mq/secrets-GMMWoG"
elasticache_secret_arn: "arn:aws:secretsmanager:us-east-1:426043895157:secret:gp/api/redis/secrets-K0zoig"
rds_secret_arn: "arn:aws:secretsmanager:us-east-1:426043895157:secret:gp/api/secrets-oFsQ2M"
Comment thread
coderabbitai[bot] marked this conversation as resolved.
Outdated

# AWS Secrets Manager key mappings used by the main app (plane-app-vars).
# The templates render:
# - `REDIS_AUTH_TOKEN_KEY` only when `env.apiSecrets.elasticache_secret_arn` is set
# - `RABBITMQ_*_KEY` only when `env.apiSecrets.amazonmq_secret_arn` is set
# - `RDS_DB_*_KEY` only when `env.apiSecrets.rds_secret_arn` is set
redis_auth_token_key: authToken
rabbitmq_user_key: username
rabbitmq_password_key: password
rds_db_host_key: host
rds_db_name_key: dbname
rds_db_password_key: password
rds_db_port_key: port
rds_db_username_key: username

# Base URL for the automation runner (defaults via template).
runner_base_url: ''

# REDIS
remote_redis_url: '' #INCASE OF REMOTE REDIS ONLY

Expand Down Expand Up @@ -519,6 +580,25 @@ env:
internal_secret: 'tyfvfqvBJAgpm9bzvf3r4urJer0Ehfdubk'
log_level: 'DEBUG'

# Names/keys that PI API uses to retrieve credentials from external secret managers.
# The templates render:
# - `RABBITMQ_*_KEY` only when `env.apiSecrets.amazonmq_secret_arn` is set
# - `RDS_DB_*_KEY` only when `env.apiSecrets.rds_secret_arn` is set
# - `FOLLOWER_RDS_DB_*_KEY` only when `services.pi.apiSecrets.follower_rds_secret_arn` is set
# - `MODEL_CUSTOM_LLM_API_KEY` only when `services.pi.apiSecrets.model_secret_arn` is set
rabbitmq_password_key: password
rabbitmq_user_key: username
rds_db_host_key: host
rds_db_name_key: dbname
rds_db_password_key: password
rds_db_port_key: port
rds_db_username_key: username
follower_rds_db_host_key: host
follower_rds_db_name_key: dbname
follower_rds_db_password_key: password
follower_rds_db_port_key: port
follower_rds_db_username_key: username

celery:
vector_sync_enabled: false
vector_sync_interval: 3
Expand Down
Loading