Skip to content

Commit

Permalink
Added changes for 3.14.x
Browse files Browse the repository at this point in the history
Signed-off-by: Jonsy13 <[email protected]>
  • Loading branch information
Jonsy13 committed Dec 16, 2024
2 parents 2ff20d1 + 89f39c3 commit 2e5ea27
Show file tree
Hide file tree
Showing 23 changed files with 142 additions and 15 deletions.
2 changes: 1 addition & 1 deletion charts/litmus-agent/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,5 @@ dependencies:
version: 3.14.0
condition: subscriber.enabled
- name: workflow-controller
version: 0.2.1
version: 0.2.2
condition: workflow-controller.enabled
3 changes: 2 additions & 1 deletion charts/litmus-agent/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Kubernetes: `>=1.16.0-0`
| | chaos-operator | 3.14.0 |
| | event-tracker | 3.14.0 |
| | subscriber | 3.14.0 |
| | workflow-controller | 0.2.1 |
| | workflow-controller | 0.2.2 |

## Installing the Chart

Expand Down Expand Up @@ -80,6 +80,7 @@ $ helm install litmus-agent litmuschaos/litmus-agent \
| image.pullPolicy | string | `"Always"` | |
| image.repository | string | `"litmuschaos.docker.scarf.sh/litmuschaos/litmus-helm-agent"` | |
| image.tag | string | `"latest"` | |
| podAnnotations | object | `{}` | |
| resources.limits.cpu | string | `"100m"` | |
| resources.limits.memory | string | `"128Mi"` | |
| resources.requests.cpu | string | `"100m"` | |
Expand Down
12 changes: 12 additions & 0 deletions charts/litmus-agent/charts/chaos-exporter/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,18 @@ app.kubernetes.io/instance: {{ .Release.Name }}
litmuschaos.io/app: {{ .Chart.Name }}
{{- end }}

{{/*
Common pod annotations
*/}}
{{- define "chaos-exporter.podAnnotations" -}}
{{- if .Values.global.podAnnotations }}
{{ toYaml .Values.global.podAnnotations }}
{{- end }}
{{- if .Values.podAnnotations }}
{{ toYaml .Values.podAnnotations }}
{{- end }}
{{- end -}}

{{/*
Create the name of the service account to use
*/}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ spec:
{{- include "chaos-exporter.selectorLabels" . | nindent 6 }}
template:
metadata:
{{- with .Values.podAnnotations }}
{{- with include "chaos-exporter.podAnnotations" . }}
annotations:
{{- toYaml . | nindent 8 }}
{{- . | indent 8 }}
{{- end }}
labels:
{{- include "chaos-exporter.labels" . | nindent 8 }}
Expand Down
12 changes: 12 additions & 0 deletions charts/litmus-agent/charts/chaos-operator/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,18 @@ app.kubernetes.io/name: {{ include "chaos-operator.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}

{{/*
Common pod annotations
*/}}
{{- define "chaos-operator.podAnnotations" -}}
{{- if .Values.global.podAnnotations }}
{{ toYaml .Values.global.podAnnotations }}
{{- end }}
{{- if .Values.podAnnotations }}
{{ toYaml .Values.podAnnotations }}
{{- end }}
{{- end -}}

{{/*
Create the name of the service account to use
*/}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ spec:
{{- include "chaos-operator.selectorLabels" . | nindent 6 }}
template:
metadata:
{{- with .Values.podAnnotations }}
{{- with include "chaos-operator.podAnnotations" . }}
annotations:
{{- toYaml . | nindent 8 }}
{{- . | indent 8 }}
{{- end }}
labels:
{{- include "chaos-operator.labels" . | nindent 8 }}
Expand Down
12 changes: 12 additions & 0 deletions charts/litmus-agent/charts/event-tracker/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,18 @@ app.kubernetes.io/name: {{ include "event-tracker.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}

{{/*
Common pod annotations
*/}}
{{- define "event-tracker.podAnnotations" -}}
{{- if .Values.global.podAnnotations }}
{{ toYaml .Values.global.podAnnotations }}
{{- end }}
{{- if .Values.podAnnotations }}
{{ toYaml .Values.podAnnotations }}
{{- end }}
{{- end -}}

{{/*
Create the name of the service account to use
*/}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ spec:
{{- include "event-tracker.selectorLabels" . | nindent 6 }}
template:
metadata:
{{- with .Values.podAnnotations }}
{{- with include "event-tracker.podAnnotations" . }}
annotations:
{{- toYaml . | nindent 8 }}
{{- . | indent 8 }}
{{- end }}
labels:
{{- include "event-tracker.labels" . | nindent 8 }}
Expand Down
12 changes: 12 additions & 0 deletions charts/litmus-agent/charts/subscriber/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,18 @@ app.kubernetes.io/name: {{ include "subscriber.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}

{{/*
Common pod annotations
*/}}
{{- define "subscriber.podAnnotations" -}}
{{- if .Values.global.podAnnotations }}
{{ toYaml .Values.global.podAnnotations }}
{{- end }}
{{- if .Values.podAnnotations }}
{{ toYaml .Values.podAnnotations }}
{{- end }}
{{- end -}}

{{/*
Create the name of the service account to use
*/}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ spec:
{{- include "subscriber.selectorLabels" . | nindent 6 }}
template:
metadata:
{{- with .Values.podAnnotations }}
{{- with include "subscriber.podAnnotations" . }}
annotations:
{{- toYaml . | nindent 8 }}
{{- . | indent 8 }}
{{- end }}
labels:
{{- include "subscriber.labels" . | nindent 8 }}
Expand Down
2 changes: 1 addition & 1 deletion charts/litmus-agent/charts/workflow-controller/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ apiVersion: v2
appVersion: "v3.3.1"
description: A Helm chart to install workflow-controller
name: workflow-controller
version: 0.2.1
version: 0.2.2
kubeVersion: ">=1.16.0-0"
home: https://litmuschaos.io
sources:
Expand Down
2 changes: 1 addition & 1 deletion charts/litmus-agent/charts/workflow-controller/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# workflow-controller

![Version: 0.2.1](https://img.shields.io/badge/Version-0.2.1-informational?style=flat-square) ![AppVersion: v3.3.1](https://img.shields.io/badge/AppVersion-v3.3.1-informational?style=flat-square)
![Version: 0.2.2](https://img.shields.io/badge/Version-0.2.2-informational?style=flat-square) ![AppVersion: v3.3.1](https://img.shields.io/badge/AppVersion-v3.3.1-informational?style=flat-square)

A Helm chart to install workflow-controller

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,18 @@ app.kubernetes.io/name: {{ include "workflow-controller.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}

{{/*
Common pod annotations
*/}}
{{- define "workflow-controller.podAnnotations" -}}
{{- if .Values.global.podAnnotations }}
{{ toYaml .Values.global.podAnnotations }}
{{- end }}
{{- if .Values.podAnnotations }}
{{ toYaml .Values.podAnnotations }}
{{- end }}
{{- end -}}

{{/*
Create the name of the service account to use
*/}}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@ spec:
{{- include "workflow-controller.selectorLabels" . | nindent 6 }}
template:
metadata:
{{- with .Values.podAnnotations }}
{{- with include "workflow-controller.podAnnotations" . }}
annotations:
{{- toYaml . | nindent 8 }}
{{- . | indent 8 }}
{{- end }}
labels:
{{- include "workflow-controller.labels" . | nindent 8 }}
Expand Down
13 changes: 13 additions & 0 deletions charts/litmus-agent/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,19 @@ app.kubernetes.io/name: {{ include "litmus-agent.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}

{{/*
Common pod annotations
*/}}
{{- define "litmus-agent.podAnnotations" -}}
{{- if .Values.global.podAnnotations }}
{{ toYaml .Values.global.podAnnotations }}
{{- end }}
{{- if .Values.podAnnotations }}
{{ toYaml .Values.podAnnotations }}
{{- end }}
{{- end -}}


{{/*
Create the name of the service account to use
*/}}
Expand Down
4 changes: 4 additions & 0 deletions charts/litmus-agent/templates/hook-pre-install-job.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ spec:
template:
metadata:
name: "{{ .Release.Name }}"
{{- with include "litmus-agent.podAnnotations" . }}
annotations:
{{- . | indent 8 }}
{{- end }}
labels:
{{- include "litmus-agent.labels" . | nindent 8 }}
spec:
Expand Down
2 changes: 2 additions & 0 deletions charts/litmus-agent/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,8 @@ image:
crds:
create: true

podAnnotations: {}

resources:
limits:
cpu: 100m
Expand Down
4 changes: 4 additions & 0 deletions charts/litmus/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ We separated service configuration from `portal.server.service` to `portal.serve
| adminConfig.VERSION | string | `"3.14.0"` | |
| allowedOrigins | string | `".*"` | |
| customLabels | object | `{}` | Additional labels |
| customPodAnnotations | object | `{}` | Additional annotations |
| existingSecret | string | `""` | Use existing secret (e.g., External Secrets) |
| image.imagePullSecrets | list | `[]` | |
| image.imageRegistryName | string | `"litmuschaos.docker.scarf.sh/litmuschaos"` | |
Expand Down Expand Up @@ -113,6 +114,7 @@ We separated service configuration from `portal.server.service` to `portal.serve
| portal.frontend.livenessProbe.successThreshold | int | `1` | |
| portal.frontend.livenessProbe.timeoutSeconds | int | `5` | |
| portal.frontend.nodeSelector | object | `{}` | |
| portal.frontend.podAnnotations | object | `{}` | |
| portal.frontend.readinessProbe.initialDelaySeconds | int | `5` | |
| portal.frontend.readinessProbe.periodSeconds | int | `10` | |
| portal.frontend.readinessProbe.successThreshold | int | `1` | |
Expand Down Expand Up @@ -145,6 +147,7 @@ We separated service configuration from `portal.server.service` to `portal.serve
| portal.server.authServer.image.pullPolicy | string | `"Always"` | |
| portal.server.authServer.image.repository | string | `"litmusportal-auth-server"` | |
| portal.server.authServer.image.tag | string | `"3.14.0"` | |
| portal.server.authServer.podAnnotations | object | `{}` | |
| portal.server.authServer.ports[0].containerPort | int | `3000` | |
| portal.server.authServer.ports[0].name | string | `"auth-server"` | |
| portal.server.authServer.ports[1].containerPort | int | `3030` | |
Expand Down Expand Up @@ -194,6 +197,7 @@ We separated service configuration from `portal.server.service` to `portal.serve
| portal.server.graphqlServer.livenessProbe.periodSeconds | int | `10` | |
| portal.server.graphqlServer.livenessProbe.successThreshold | int | `1` | |
| portal.server.graphqlServer.livenessProbe.timeoutSeconds | int | `5` | |
| portal.server.graphqlServer.podAnnotations | object | `{}` | |
| portal.server.graphqlServer.ports[0].containerPort | int | `8080` | |
| portal.server.graphqlServer.ports[0].name | string | `"gql-server"` | |
| portal.server.graphqlServer.ports[1].containerPort | int | `8000` | |
Expand Down
27 changes: 27 additions & 0 deletions charts/litmus/templates/_helpers.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -136,3 +136,30 @@ mongodb://{{ trimSuffix "," $hosts }}/admin
{{- end -}}
{{- end -}}

{{/* section to define the podannotations for the different components */}}
{{- define "litmus-portal.podannotations.auth-server" -}}
{{- if .Values.customPodAnnotations }}
{{ toYaml .Values.customPodAnnotations }}
{{- end }}
{{- if .Values.portal.server.authServer.podAnnotations }}
{{ toYaml .Values.portal.server.authServer.podAnnotations }}
{{- end }}
{{- end -}}

{{- define "litmus-portal.podannotations.graphql-server" -}}
{{- if .Values.customPodAnnotations }}
{{ toYaml .Values.customPodAnnotations }}
{{- end }}
{{- if .Values.portal.server.graphqlServer.podAnnotations }}
{{ toYaml .Values.portal.server.graphqlServer.podAnnotations }}
{{- end }}
{{- end -}}

{{- define "litmus-portal.podannotations.frontend" -}}
{{- if .Values.customPodAnnotations }}
{{ toYaml .Values.customPodAnnotations }}
{{- end }}
{{- if .Values.portal.frontend.podAnnotations }}
{{ toYaml .Values.portal.frontend.podAnnotations }}
{{- end }}
{{- end -}}
4 changes: 4 additions & 0 deletions charts/litmus/templates/auth-server-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ spec:
{{- if .Values.portal.server.customLabels }}
{{ toYaml .Values.portal.server.customLabels | nindent 8 }}
{{- end }}
{{- if include "litmus-portal.podannotations.auth-server" . }}
annotations:
{{- include "litmus-portal.podannotations.auth-server" . | indent 8 }}
{{- end}}
spec:
automountServiceAccountToken: {{ .Values.portal.server.authServer.automountServiceAccountToken }}
{{- if .Values.image.imagePullSecrets }}
Expand Down
4 changes: 4 additions & 0 deletions charts/litmus/templates/frontend-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ spec:
{{- if .Values.portal.frontend.customLabels }}
{{ toYaml .Values.portal.frontend.customLabels | nindent 8 }}
{{- end }}
{{- if include "litmus-portal.podannotations.frontend" . }}
annotations:
{{- include "litmus-portal.podannotations.frontend" . | indent 8 }}
{{- end}}
spec:
automountServiceAccountToken: {{ .Values.portal.frontend.automountServiceAccountToken }}
{{- if .Values.image.imagePullSecrets }}
Expand Down
4 changes: 4 additions & 0 deletions charts/litmus/templates/server-deployment.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ spec:
{{- if .Values.portal.server.customLabels }}
{{ toYaml .Values.portal.server.customLabels | nindent 8 }}
{{- end }}
{{- if include "litmus-portal.podannotations.graphql-server" . }}
annotations:
{{- include "litmus-portal.podannotations.graphql-server" . | indent 8 }}
{{- end}}
spec:
automountServiceAccountToken: {{ .Values.portal.server.graphqlServer.automountServiceAccountToken }}
{{- if .Values.image.imagePullSecrets }}
Expand Down
6 changes: 5 additions & 1 deletion charts/litmus/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
# Declare variables to be passed into your templates.
nameOverride: ""

# -- Additional annotations
customPodAnnotations: {}
# -- Additional labels
customLabels: {}
# my.company.com/concourse-cd: 2
Expand Down Expand Up @@ -123,6 +125,7 @@ portal:
containerPort: 8185
customLabels: {}
# my.company.com/tier: "frontend"
podAnnotations: {}

resources:
# We usually recommend not to specify default resources and to leave this as a conscious
Expand Down Expand Up @@ -280,6 +283,7 @@ portal:
periodSeconds: 10
successThreshold: 1
timeoutSeconds: 1
podAnnotations: {}
authServer:
replicas: 1
autoscaling:
Expand Down Expand Up @@ -328,7 +332,7 @@ portal:
ephemeral-storage: "1Gi"
volumeMounts: []
volumes: []

podAnnotations: {}
nodeSelector: {}
tolerations: []
affinity: {}
Expand Down

0 comments on commit 2e5ea27

Please sign in to comment.