Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
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
8 changes: 4 additions & 4 deletions charts/multiwoven/Chart.yaml → charts/aisquared/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
apiVersion: v2
name: multiwoven
name: aisquared
description: |
Multiwoven is an open-source reverse ETL tool, offering an alternative to qHightouch, Census, and similar platforms. 🔥
AI Squared is an open-source reverse ETL tool, offering an alternative to qHightouch, Census, and similar platforms. 🔥
# kubeVersion: ">=1.16.0"
type: application
version: 0.62.0
appVersion: "0.62.0"
version: 0.63.0
appVersion: "0.63.0"
home: https://github.com/Multiwoven/multiwoven
sources:
- https://docs.squared.ai/open-source/guides/setup/helm
Expand Down
69 changes: 69 additions & 0 deletions charts/aisquared/templates/aisquared-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: {{ include "chart.fullname" . }}-config
namespace: {{ .Values.kubernetesNamespace }}
labels:
io.kompose.service: {{ include "chart.fullname" . }}-config
{{- include "chart.labels" . | nindent 4 }}
data:
ALLOWED_HOST: {{ .Values.aisquaredConfig.allowedHost | quote }}
API_HOST: {{ .Values.aisquaredConfig.apiHost | quote }}
APP_ENV: {{ .Values.aisquaredConfig.appEnv | quote }}
APP_REVISION: {{ .Values.aisquaredConfig.appRevision | quote }}
APPSIGNAL_APP_ENV: {{ .Values.aisquaredConfig.appEnv | quote }}
APPSIGNAL_PUSH_API_KEY: {{ .Values.aisquaredConfig.appsignalPushApiKey | quote }}
AWS_ACCESS_KEY_ID: {{ .Values.aisquaredConfig.awsAccessKeyId | quote }}
AWS_SECRET_ACCESS_KEY: {{ .Values.aisquaredConfig.awsSecretAccessKey | quote }}
BRAND_NAME: {{ .Values.aisquaredConfig.smtpBrandName | quote }}
DATABRICKS_DRIVER_PATH: {{ .Values.aisquaredConfig.databricksDriverPath | quote }}
DB_PORT: {{ .Values.aisquaredConfig.dbPort | quote }}
DB_HOST: {{ .Values.aisquaredConfig.dbHost | quote }}
{{ if not .Values.secretsStore.enabled }}
DB_PASSWORD: {{ .Values.aisquaredConfig.dbPassword | quote }}
DB_USERNAME: {{ .Values.aisquaredConfig.dbUsername | quote }}
{{ end }}
GRPC_ENABLE_FORK_SUPPORT: {{ .Values.aisquaredConfig.grpcEnableForkSupport | quote }}
JWT_SECRET: {{ .Values.aisquaredConfig.jwtSecret | quote }}
NEW_RELIC_KEY: {{ .Values.aisquaredConfig.newRelicKey | quote }}
RAILS_ENV: {{ .Values.aisquaredConfig.railsEnv | quote }}
RAILS_LOG_LEVEL: {{ .Values.aisquaredConfig.railsLogLevel | quote }}
SECRET_KEY_BASE: {{ .Values.aisquaredConfig.secretKeyBase | quote }}
SKIP_DB_MIGRATION: {{ .Values.aisquaredConfig.skipDbMigration | quote }}
SMTP_ADDRESS: {{ .Values.aisquaredConfig.smtpAddress | quote }}
SMTP_HOST: {{ .Values.aisquaredConfig.smtpHost | quote }}
SMTP_PASSWORD: {{ .Values.aisquaredConfig.smtpPassword | quote }}
SMTP_PORT: {{ .Values.aisquaredConfig.smtpPort | quote }}
SMTP_USERNAME: {{ .Values.aisquaredConfig.smtpUsername | quote }}
SMTP_SENDER_EMAIL: {{ .Values.aisquaredConfig.smtpSenderEmail | quote }}
SNOWFLAKE_DRIVER_PATH: {{ .Values.aisquaredConfig.snowflakeDriverPath | quote }}
Comment on lines +15 to +39

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🛠️ Refactor suggestion

⚠️ Potential issue

Do not store secrets in a ConfigMap; move sensitive values to Kubernetes Secrets (or CSI).

Several keys here are sensitive and should not be stored in a ConfigMap: APPSIGNAL_PUSH_API_KEY, AWS_SECRET_ACCESS_KEY, JWT_SECRET, NEW_RELIC_KEY, SECRET_KEY_BASE, SMTP_PASSWORD, DB_PASSWORD/DB_USERNAME (already gated), TEMPORAL_POSTGRES_PASSWORD, etc. ConfigMaps are not meant for secrets and are readable cluster-wide by default RBAC. You already gate DB credentials behind .Values.secretsStore.enabled; apply the same pattern or move these to a Secret/SecretProviderClass and reference them via env.valueFrom.secretKeyRef in your Deployments.

Proposed minimal change for this template (gating additional secrets to avoid placing them in the ConfigMap when CSI is enabled):

-  APPSIGNAL_PUSH_API_KEY: {{ .Values.aisquaredConfig.appsignalPushApiKey | quote }}
+  {{- if not .Values.secretsStore.enabled }}
+  APPSIGNAL_PUSH_API_KEY: {{ .Values.aisquaredConfig.appsignalPushApiKey | quote }}
+  {{- end }}
-  AWS_SECRET_ACCESS_KEY: {{ .Values.aisquaredConfig.awsSecretAccessKey | quote }}
+  {{- if not .Values.secretsStore.enabled }}
+  AWS_SECRET_ACCESS_KEY: {{ .Values.aisquaredConfig.awsSecretAccessKey | quote }}
+  {{- end }}
-  JWT_SECRET: {{ .Values.aisquaredConfig.jwtSecret | quote }}
+  {{- if not .Values.secretsStore.enabled }}
+  JWT_SECRET: {{ .Values.aisquaredConfig.jwtSecret | quote }}
+  {{- end }}
-  NEW_RELIC_KEY: {{ .Values.aisquaredConfig.newRelicKey | quote }}
+  {{- if not .Values.secretsStore.enabled }}
+  NEW_RELIC_KEY: {{ .Values.aisquaredConfig.newRelicKey | quote }}
+  {{- end }}
-  SECRET_KEY_BASE: {{ .Values.aisquaredConfig.secretKeyBase | quote }}
+  {{- if not .Values.secretsStore.enabled }}
+  SECRET_KEY_BASE: {{ .Values.aisquaredConfig.secretKeyBase | quote }}
+  {{- end }}
-  SMTP_PASSWORD: {{ .Values.aisquaredConfig.smtpPassword | quote }}
+  {{- if not .Values.secretsStore.enabled }}
+  SMTP_PASSWORD: {{ .Values.aisquaredConfig.smtpPassword | quote }}
+  {{- end }}
-  TEMPORAL_POSTGRES_PASSWORD: {{ .Values.aisquaredConfig.temporalPostgresPassword | quote }}
+  {{- if not .Values.secretsStore.enabled }}
+  TEMPORAL_POSTGRES_PASSWORD: {{ .Values.aisquaredConfig.temporalPostgresPassword | quote }}
+  {{- end }}

Follow-up: I can also generate the corresponding Deployment env valueFrom.secretKeyRef patches and, if desired, a Secret template or CSI SecretProviderClass entries for these keys. Would you like me to open a follow-up PR/commit for that?

Also applies to: 53-55, 27-31, 23-25, 35-35

STORAGE_ACCESS_KEY: {{ .Values.aisquaredConfig.storageAccessKey }}
STORAGE_ACCOUNT_NAME: {{ .Values.aisquaredConfig.storageAccountName }}
SYNC_EXTRACTOR_BATCH_SIZE: {{ .Values.aisquaredConfig.syncExtractorBatchSize | quote }}
SYNC_EXTRACTOR_THREAD_POOL_SIZE: {{ .Values.aisquaredConfig.syncExtractorThreadPoolSize | quote }}
SYNC_LOADER_BATCH_SIZE: {{ .Values.aisquaredConfig.syncLoaderBatchSize | quote }}
SYNC_LOADER_THREAD_POOL_SIZE: {{ .Values.aisquaredConfig.syncLoaderThreadPoolSize | quote }}
TEMPORAL_ACTIVITY_THREAD_POOL_SIZE: {{ .Values.aisquaredConfig.temporalActivityThreadPoolSize | quote }}
TEMPORAL_CLIENT_CHAIN: {{ .Values.aisquaredConfig.temporalClientChain | quote }}
TEMPORAL_CLIENT_KEY: {{ .Values.aisquaredConfig.temporalClientKey | quote }}
TEMPORAL_HOST: {{ .Values.aisquaredConfig.temporalHost | quote }}
TEMPORAL_NAMESPACE: {{ .Values.aisquaredConfig.temporalNamespace | quote }}
TEMPORAL_PORT: {{ .Values.aisquaredConfig.temporalPort | quote }}
TEMPORAL_POSTGRES_DEFAULT_PORT: {{ .Values.aisquaredConfig.temporalPostgresDefaultPort | quote }}
TEMPORAL_POSTGRES_PASSWORD: {{ .Values.aisquaredConfig.temporalPostgresPassword | quote }}
TEMPORAL_POSTGRES_USER: {{ .Values.aisquaredConfig.temporalPostgresUser | quote }}
TEMPORAL_POSTGRESQL_VERSION: {{ .Values.aisquaredConfig.temporalPostgresqlVersion | quote }}
TEMPORAL_ROOT_CERT: {{ .Values.aisquaredConfig.temporalRootCert | quote }}
TEMPORAL_TASK_QUEUE: {{ .Values.aisquaredConfig.temporalTaskQueue | quote }}
TEMPORAL_UI_VERSION: {{ .Values.aisquaredConfig.temporalUiVersion | quote }}
TEMPORAL_VERSION: {{ .Values.aisquaredConfig.temporalVersion | quote }}
TEMPORAL_WORKFLOW_THREAD_POOL_SIZE: {{ .Values.aisquaredConfig.temporalWorkflowThreadPoolSize | quote }}
UI_HOST: {{ .Values.aisquaredConfig.uiHost | quote }}
USER_EMAIL_VERIFICATION: {{ .Values.aisquaredConfig.userEmailVerification | quote }}
VITE_API_HOST: {{ .Values.aisquaredConfig.viteApiHost | quote }}
VITE_APPSIGNAL_PUSH_API_KEY: {{ .Values.aisquaredConfig.viteAppsignalPushApiKey | quote }}
VITE_BRAND_NAME: {{ .Values.aisquaredConfig.viteBrandName | quote }}
VITE_LOGO_URL: {{ .Values.aisquaredConfig.viteLogoUrl | quote }}
VITE_BRAND_COLOR: {{ .Values.aisquaredConfig.viteBrandColor | quote }}
VITE_BRAND_HOVER_COLOR: {{ .Values.aisquaredConfig.viteBrandHoverColor | quote }}
VITE_FAV_ICON_URL: {{ .Values.aisquaredConfig.viteFavIconUrl | quote }}
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ metadata:
annotations:
{{ if .Values.externalDNS.enabled }}
{{- if .Values.temporal.enabled }}
external-dns.alpha.kubernetes.io/hostname: "{{ .Values.multiwovenConfig.uiHost }},{{ .Values.multiwovenConfig.apiHost }},{{ .Values.multiwovenConfig.workerHost }},{{ .Values.multiwovenConfig.solidWorkerHost }},{{ .Values.multiwovenConfig.temporalUiHost }}"
external-dns.alpha.kubernetes.io/hostname: "{{ .Values.aisquaredConfig.uiHost }},{{ .Values.aisquaredConfig.apiHost }},{{ .Values.aisquaredConfig.workerHost }},{{ .Values.aisquaredConfig.solidWorkerHost }},{{ .Values.aisquaredConfig.temporalUiHost }}"
{{- end }}
{{- if not .Values.temporal.enabled }}
external-dns.alpha.kubernetes.io/hostname: "{{ .Values.multiwovenConfig.uiHost }},{{ .Values.multiwovenConfig.apiHost }},{{ .Values.multiwovenConfig.workerHost }},{{ .Values.multiwovenConfig.solidWorkerHost }}"
external-dns.alpha.kubernetes.io/hostname: "{{ .Values.aisquaredConfig.uiHost }},{{ .Values.aisquaredConfig.apiHost }},{{ .Values.aisquaredConfig.workerHost }},{{ .Values.aisquaredConfig.solidWorkerHost }}"
{{- end }}
{{ end }}

Expand All @@ -24,12 +24,12 @@ metadata:
{{ if .Values.nginxIngress.enabled }}
kubernetes.io/ingress.class: nginx
nginx.ingress.kubernetes.io/backend-protocol: "HTTP"
cert-manager.io/issuer: {{ .Values.multiwovenConfig.tlsCertIssuer }}
cert-manager.io/issuer: {{ .Values.aisquaredConfig.tlsCertIssuer }}
nginx.ingress.kubernetes.io/ssl-redirect: "true"
nginx.ingress.kubernetes.io/force-ssl-redirect: "true"
nginx.ingress.kubernetes.io/whitelist-source-range: {{ .Values.multiwovenConfig.allowedSourceIP }}
nginx.ingress.kubernetes.io/proxy-body-size: {{ .Values.multiwovenConfig.nginxProxyBodySize }}
{{ if not .Values.nginxIngress.enableMetrics }}
nginx.ingress.kubernetes.io/whitelist-source-range: {{ .Values.aisquaredConfig.allowedSourceIP }}
nginx.ingress.kubernetes.io/proxy-body-size: {{ .Values.aisquaredConfig.nginxProxyBodySize }}
{{ if .Values.nginxIngress.enableMetrics }}
nginx.ingress.kubernetes.io/server-snippet: |
location = /metrics {
return 403;
Expand All @@ -50,12 +50,12 @@ spec:
ingressClassName: nginx
tls:
- hosts:
- {{ .Values.multiwovenConfig.uiHost }}
- {{ .Values.multiwovenConfig.apiHost }}
- {{ .Values.multiwovenConfig.workerHost }}
- {{ .Values.multiwovenConfig.solidWorkerHost }}
- {{ .Values.aisquaredConfig.uiHost }}
- {{ .Values.aisquaredConfig.apiHost }}
- {{ .Values.aisquaredConfig.workerHost }}
- {{ .Values.aisquaredConfig.solidWorkerHost }}
{{ if .Values.temporal.enabled }}
- {{ .Values.multiwovenConfig.temporalUiHost }}
- {{ .Values.aisquaredConfig.temporalUiHost }}
{{ end }}
secretName: mw-tls-cert
{{ end }}
Comment on lines 60 to 61

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🛠️ Refactor suggestion

Hardcoded TLS secret name “mw-tls-cert”; make it configurable (and align with rebrand).

To avoid coupling to a legacy name and support different environments, make the secret name configurable (with a safe default).

-    secretName: mw-tls-cert
+    secretName: {{ .Values.aisquaredConfig.tlsSecretName | default "mw-tls-cert" }}

If you prefer a pure rebrand, default to "aisquared-tls-cert" instead.

📝 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
secretName: mw-tls-cert
{{ end }}
secretName: {{ .Values.aisquaredConfig.tlsSecretName | default "mw-tls-cert" }}
{{ end }}
🤖 Prompt for AI Agents
In charts/aisquared/templates/aisquared-ingress.yaml around lines 60-61, the TLS
secretName is hardcoded to "mw-tls-cert"; change this to use a Helm chart value
(e.g. .Values.tls.secretName) with a safe default in values.yaml (preferably
"aisquared-tls-cert" for rebrand) so deployments can override per environment;
update values.yaml to include tls.secretName: "aisquared-tls-cert" and modify
the template to reference that value, ensuring tests/README mention how to
override it.

Expand All @@ -67,7 +67,7 @@ spec:
ingressClassName: alb
{{ end }}
rules:
- host: {{ .Values.multiwovenConfig.uiHost }}
- host: {{ .Values.aisquaredConfig.uiHost }}
http:
paths:
- path: /
Expand All @@ -76,8 +76,8 @@ spec:
service:
name: '{{ include "chart.fullname" . }}-ui'
port:
number: {{ (index .Values.multiwovenUI.ports 0).port }}
- host: {{ .Values.multiwovenConfig.apiHost }}
number: {{ (index .Values.aisquaredUI.ports 0).port }}
- host: {{ .Values.aisquaredConfig.apiHost }}
http:
paths:
- path: /
Expand All @@ -86,8 +86,8 @@ spec:
service:
name: '{{ include "chart.fullname" . }}-server'
port:
number: {{ (index .Values.multiwovenServer.ports 0).port }}
- host: {{ .Values.multiwovenConfig.workerHost }}
number: {{ (index .Values.aisquaredServer.ports 0).port }}
- host: {{ .Values.aisquaredConfig.workerHost }}
http:
paths:
- path: /
Expand All @@ -96,8 +96,8 @@ spec:
service:
name: '{{ include "chart.fullname" . }}-worker'
port:
number: {{ .Values.multiwovenWorker.healthPort }}
- host: {{ .Values.multiwovenConfig.solidWorkerHost }}
number: {{ .Values.aisquaredWorker.healthPort }}
- host: {{ .Values.aisquaredConfig.solidWorkerHost }}
http:
paths:
- path: /
Expand All @@ -106,9 +106,9 @@ spec:
service:
name: '{{ include "chart.fullname" . }}-solid-worker'
port:
number: {{ .Values.multiwovenSolidWorker.healthPort }}
number: {{ .Values.aisquaredSolidWorker.healthPort }}
{{ if .Values.temporal.enabled }}
- host: {{ .Values.multiwovenConfig.temporalUiHost }}
- host: {{ .Values.aisquaredConfig.temporalUiHost }}
http:
paths:
- backend:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{{ if .Values.multiwovenPostgresql.enabled }}
{{ if .Values.aisquaredPostgresql.enabled }}
apiVersion: apps/v1
kind: Deployment
metadata:
Expand All @@ -8,23 +8,23 @@ metadata:
io.kompose.service: {{ include "chart.fullname" . }}-postgresql
{{- include "chart.labels" . | nindent 4 }}
annotations:
{{- with .Values.multiwovenPostgresql.annotations }}
{{- with .Values.aisquaredPostgresql.annotations }}
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
replicas: {{ .Values.multiwovenPostgresql.replicas }}
replicas: {{ .Values.aisquaredPostgresql.replicas }}
selector:
matchLabels:
io.kompose.service: {{ include "chart.fullname" . }}-postgresql
{{- include "chart.selectorLabels" . | nindent 6 }}
template:
metadata:
labels:
io.kompose.network/multiwoven-server-default: "true"
io.kompose.network/aisquared-server-default: "true"
io.kompose.service: {{ include "chart.fullname" . }}-postgresql
{{- include "chart.selectorLabels" . | nindent 8 }}
annotations:
{{- with .Values.multiwovenPostgresql.annotations }}
{{- with .Values.aisquaredPostgresql.annotations }}
{{ toYaml . | nindent 8 }}
{{- end }}
spec:
Expand All @@ -42,7 +42,7 @@ spec:
name: {{ include "chart.fullname" . }}-config
- name: KUBERNETES_CLUSTER_DOMAIN
value: {{ quote .Values.kubernetesClusterDomain }}
image: {{ .Values.multiwovenPostgresql.multiwovenPostgresql.image.repository }}:{{ .Values.multiwovenPostgresql.multiwovenPostgresql.image.tag | default .Chart.AppVersion }}
image: {{ .Values.aisquaredPostgresql.aisquaredPostgresql.image.repository }}:{{ .Values.aisquaredPostgresql.aisquaredPostgresql.image.tag | default .Chart.AppVersion }}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

⚠️ Potential issue

Likely incorrect values path (double aisquaredPostgresql nesting)

These paths look off and will render empty unless the values are double-nested. Everywhere else (replicas/annotations) uses a single aisquaredPostgresql. Recommend flattening to the common pattern.

-        image: {{ .Values.aisquaredPostgresql.aisquaredPostgresql.image.repository }}:{{ .Values.aisquaredPostgresql.aisquaredPostgresql.image.tag | default .Chart.AppVersion }}
+        image: {{ .Values.aisquaredPostgresql.image.repository }}:{{ .Values.aisquaredPostgresql.image.tag | default .Chart.AppVersion }}
@@
-        resources: {{- toYaml .Values.aisquaredPostgresql.aisquaredPostgresql.resources | nindent 10 }}
+        resources: {{- toYaml .Values.aisquaredPostgresql.resources | nindent 10 }}

Also applies to: 59-59

🤖 Prompt for AI Agents
In charts/aisquared/templates/aisquared-postgresql-deployment.yaml around lines
45 and 59, the values path uses a double nesting
(.Values.aisquaredPostgresql.aisquaredPostgresql.*) which will render empty;
change those references to the single-nested common pattern
(.Values.aisquaredPostgresql.image.repository and
.Values.aisquaredPostgresql.image.tag | default .Chart.AppVersion) and update
the other occurrence on line 59 similarly so all image values reference
.Values.aisquaredPostgresql.* consistently.

livenessProbe:
initialDelaySeconds: 30
periodSeconds: 10
Expand All @@ -56,7 +56,7 @@ spec:
periodSeconds: 10
tcpSocket:
port: 5432
resources: {{- toYaml .Values.multiwovenPostgresql.multiwovenPostgresql.resources | nindent 10 }}
resources: {{- toYaml .Values.aisquaredPostgresql.aisquaredPostgresql.resources | nindent 10 }}
volumeMounts:
- mountPath: /var/lib/postgresql/data
subPath: postgres
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{{ if .Values.multiwovenPostgresql.enabled }}
{{ if .Values.aisquaredPostgresql.enabled }}
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{{ if .Values.multiwovenPostgresql.enabled }}
{{ if .Values.aisquaredPostgresql.enabled }}
apiVersion: v1
kind: Service
metadata:
Expand All @@ -8,10 +8,10 @@ metadata:
io.kompose.service: {{ include "chart.fullname" . }}-postgresql
{{- include "chart.labels" . | nindent 4 }}
spec:
type: {{ .Values.multiwovenPostgresql.type }}
type: {{ .Values.aisquaredPostgresql.type }}
selector:
io.kompose.service: {{ include "chart.fullname" . }}-postgresql
{{- include "chart.selectorLabels" . | nindent 4 }}
ports:
{{- .Values.multiwovenPostgresql.ports | toYaml | nindent 2 -}}
{{- .Values.aisquaredPostgresql.ports | toYaml | nindent 2 -}}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Verification agent

🧩 Analysis chain

Tab character breaks YAML indentation; replace with spaces.
There is a leading tab before the Helm expression. Tabs are invalid for YAML indentation and may render an invalid manifest. Replace with spaces.

Apply this diff:

-	{{- .Values.aisquaredPostgresql.ports | toYaml | nindent 2 -}}
+  {{- .Values.aisquaredPostgresql.ports | toYaml | nindent 2 -}}

Optionally, you can also remove the preceding two literal spaces and change nindent to 4 for clarity:

-  {{- .Values.aisquaredPostgresql.ports | toYaml | nindent 2 -}}
+{{- .Values.aisquaredPostgresql.ports | toYaml | nindent 4 -}}

To scan for similar tab issues elsewhere:


🏁 Script executed:

#!/bin/bash
# Find lines starting with tabs in Helm templates
rg -nP '^\t' charts/aisquared/templates

Length of output: 616


Replace leading tabs with spaces in Helm templates
Tabs are invalid for YAML indentation and will break the rendered manifests. We’ve identified instances across all charts/aisquared/templates:

• temporal-ui-service.yaml:19
• temporal-service.yaml:20
• aisquared-ui-service.yaml:19
• aisquared-server-service.yaml:19
• aisquared-postgresql-service.yaml:16

Each of these lines begins with a tab before the Helm expression. Please replace the leading tab with two spaces (or adjust to no leading spaces + nindent 4 for consistency). For example, in charts/aisquared/templates/aisquared-postgresql-service.yaml:

-	{{- .Values.aisquaredPostgresql.ports | toYaml | nindent 2 -}}
+  {{- .Values.aisquaredPostgresql.ports | toYaml | nindent 2 -}}

Or, for clearer alignment, you can remove the two spaces and bump nindent to 4:

-  {{- .Values.aisquaredPostgresql.ports | toYaml | nindent 2 -}}
+{{- .Values.aisquaredPostgresql.ports | toYaml | nindent 4 -}}

Apply the same fix pattern to the other four templates above to ensure all YAML is valid.

📝 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
{{- .Values.aisquaredPostgresql.ports | toYaml | nindent 2 -}}
{{- .Values.aisquaredPostgresql.ports | toYaml | nindent 2 -}}
🤖 Prompt for AI Agents
In charts/aisquared/templates/aisquared-postgresql-service.yaml around line 16,
the line starts with a tab character before the Helm expression which produces
invalid YAML; replace the leading tab with two spaces (or remove leading spaces
and change nindent to 4 for consistent alignment) so the Helm template output is
correctly indented—apply the same replacement pattern to the other files listed
(temporal-ui-service.yaml:19, temporal-service.yaml:20,
aisquared-ui-service.yaml:19, aisquared-server-service.yaml:19).

{{ end }}
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ metadata:
io.kompose.service: {{ include "chart.fullname" . }}-server
{{- include "chart.labels" . | nindent 4 }}
annotations:
{{- with .Values.multiwovenServer.annotations }}
{{- with .Values.aisquaredServer.annotations }}
{{ toYaml . | nindent 4 }}
{{- end }}
spec:
replicas: {{ .Values.multiwovenServer.replicas }}
replicas: {{ .Values.aisquaredServer.replicas }}
selector:
matchLabels:
app: {{ include "chart.fullname" . }}-server
Expand All @@ -25,18 +25,18 @@ spec:
io.kompose.service: {{ include "chart.fullname" . }}-server
{{- include "chart.selectorLabels" . | nindent 8 }}
annotations:
{{- with .Values.multiwovenServer.annotations }}
{{- with .Values.aisquaredServer.annotations }}
{{ toYaml . | nindent 8 }}
{{- end }}
spec:
serviceAccountName: {{ .Values.serviceAccount.create | ternary .Values.serviceAccount.name "default" }}
automountServiceAccountToken: {{ .Values.automountServiceAccountToken.enabled }}
securityContext:
fsGroup: {{ .Values.multiwovenServer.podSecurityContext.fsGroup }}
fsGroup: {{ .Values.aisquaredServer.podSecurityContext.fsGroup }}
initContainers:
{{ if .Values.securityContext.readOnlyRootFilesystem }}
- name: copy-config
image: {{ .Values.multiwovenServer.multiwovenServer.image.repository }}:{{ .Values.multiwovenServer.multiwovenServer.image.tag | default .Chart.AppVersion }}
image: {{ .Values.aisquaredServer.aisquaredServer.image.repository }}:{{ .Values.aisquaredServer.aisquaredServer.image.tag | default .Chart.AppVersion }}
imagePullPolicy: {{ .Values.globalImagePullPolicy }}
command:
- /bin/sh
Expand All @@ -49,8 +49,8 @@ spec:
- name: rails-config
mountPath: /mnt/rails
securityContext:
runAsUser: {{ .Values.multiwovenServer.multiwovenServer.containerSecurityContext.runAsUser }}
runAsGroup: {{ .Values.multiwovenServer.multiwovenServer.containerSecurityContext.runAsGroup }}
runAsUser: {{ .Values.aisquaredServer.aisquaredServer.containerSecurityContext.runAsUser }}
runAsGroup: {{ .Values.aisquaredServer.aisquaredServer.containerSecurityContext.runAsGroup }}
privileged: false
allowPrivilegeEscalation: {{ .Values.securityContext.allowPrivilegeEscalation }}
readOnlyRootFilesystem: {{ .Values.securityContext.readOnlyRootFilesystem }}
Expand All @@ -62,7 +62,7 @@ spec:
{{- end }}
{{- end }}
{{ end }}
{{ if .Values.multiwovenConfig.azureSpot }}
{{ if .Values.aisquaredConfig.azureSpot }}
tolerations:
- key: "kubernetes.azure.com/scalesetpriority"
operator: "Equal"
Expand Down Expand Up @@ -107,20 +107,20 @@ spec:
{{ end }}
{{ if .Values.multipleDbHosts.enabled }}
- name: DB_HOST
value: {{ .Values.multipleDbHosts.multiwovenDBHost }}
value: {{ .Values.multipleDbHosts.aisquaredDBHost }}
- name: DB_NAME
value: {{ .Values.multipleDbHosts.multiwovenDBName }}
value: {{ .Values.multipleDbHosts.aisquaredDBName }}
{{ end }}
- name: KUBERNETES_CLUSTER_DOMAIN
value: {{ quote .Values.kubernetesClusterDomain }}
envFrom:
- configMapRef:
name: {{ include "chart.fullname" . }}-config
image: {{ .Values.multiwovenServer.multiwovenServer.image.repository }}:{{ .Values.multiwovenServer.multiwovenServer.image.tag | default .Chart.AppVersion }}
image: {{ .Values.aisquaredServer.aisquaredServer.image.repository }}:{{ .Values.aisquaredServer.aisquaredServer.image.tag | default .Chart.AppVersion }}
imagePullPolicy: {{ .Values.globalImagePullPolicy }}
securityContext:
Comment on lines 120 to 121

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🛠️ Refactor suggestion

Duplicate imagePullPolicy keys — unify to a single declaration

The container has two imagePullPolicy keys. Duplicate keys are unsafe and can lead to unexpected behavior.

Keep only one, preferably the values-driven one:

@@
-        imagePullPolicy: {{ .Values.globalImagePullPolicy }}
@@
-        imagePullPolicy: Always
+        # imagePullPolicy controlled via .Values.globalImagePullPolicy

Also applies to: 150-151

🤖 Prompt for AI Agents
In charts/aisquared/templates/aisquared-server-deployment.yaml around lines
120-121 (and likewise at 150-151), there are duplicate imagePullPolicy keys in
the same container spec; remove the redundant key so only the values-driven
declaration (imagePullPolicy: {{ .Values.globalImagePullPolicy }}) remains,
ensuring each container has a single imagePullPolicy entry and updating or
deleting the other duplicate occurrence.

runAsUser: {{ .Values.multiwovenServer.multiwovenServer.containerSecurityContext.runAsUser }}
runAsGroup: {{ .Values.multiwovenServer.multiwovenServer.containerSecurityContext.runAsGroup }}
runAsUser: {{ .Values.aisquaredServer.aisquaredServer.containerSecurityContext.runAsUser }}
runAsGroup: {{ .Values.aisquaredServer.aisquaredServer.containerSecurityContext.runAsGroup }}
privileged: false
allowPrivilegeEscalation: {{ .Values.securityContext.allowPrivilegeEscalation }}
readOnlyRootFilesystem: {{ .Values.securityContext.readOnlyRootFilesystem }}
Expand All @@ -134,23 +134,23 @@ spec:
livenessProbe:
httpGet:
path: /
port: {{ (index .Values.multiwovenServer.ports 0).port }}
port: {{ (index .Values.aisquaredServer.ports 0).port }}
initialDelaySeconds: 15
periodSeconds: 10
name: {{ include "chart.fullname" . }}-server
ports:
- containerPort: {{ (index .Values.multiwovenServer.ports 0).port }}
- containerPort: {{ (index .Values.aisquaredServer.ports 0).port }}
readinessProbe:
httpGet:
path: /
port: {{ (index .Values.multiwovenServer.ports 0).port }}
port: {{ (index .Values.aisquaredServer.ports 0).port }}
initialDelaySeconds: 5
periodSeconds: 10
resources: {{- toYaml .Values.multiwovenServer.multiwovenServer.resources | nindent 10 }}
resources: {{- toYaml .Values.aisquaredServer.aisquaredServer.resources | nindent 10 }}
imagePullPolicy: Always
volumeMounts:
{{ if .Values.secretsStore.enabled }}
- name: multiwoven-secrets-store
- name: aisquared-secrets-store
mountPath: /run/secrets/mw-secrets
readOnly: true
{{ end }}
Expand Down Expand Up @@ -180,7 +180,7 @@ spec:
path: ./temporal.pem
{{ end }}
{{ if .Values.secretsStore.enabled }}
- name: multiwoven-secrets-store
- name: aisquared-secrets-store
csi:
driver: secrets-store.csi.k8s.io
readOnly: true
Expand All @@ -200,7 +200,7 @@ spec:
emptyDir: {}
{{ end }}
restartPolicy: Always
{{ if .Values.multiwovenConfig.privateRepo }}
{{ if .Values.aisquaredConfig.privateRepo }}
imagePullSecrets:
- name: {{ .Values.multiwovenConfig.registrySecretName }}
- name: {{ .Values.aisquaredConfig.registrySecretName }}
{{ end }}
Loading
Loading