mirror of
https://github.com/bitnami/charts.git
synced 2026-03-05 06:47:25 +08:00
[bitnami/jasperreports] fix: 🔒 Move service-account token auto-mount to pod declaration (#22485)
* [bitnami/jasperreports] fix: 🔒 Move service-account token auto-mount to pod declaration Signed-off-by: Javier Salmeron Garcia <jsalmeron@vmware.com> * Update bitnami/jasperreports/values.yaml Co-authored-by: Jose Antonio Carmona <jcarmona@vmware.com> Signed-off-by: Javier J. Salmerón-García <jsalmeron@vmware.com> * Update README.md with readme-generator-for-helm Signed-off-by: Bitnami Containers <bitnami-bot@vmware.com> --------- Signed-off-by: Javier Salmeron Garcia <jsalmeron@vmware.com> Signed-off-by: Javier J. Salmerón-García <jsalmeron@vmware.com> Signed-off-by: Bitnami Containers <bitnami-bot@vmware.com> Co-authored-by: Jose Antonio Carmona <jcarmona@vmware.com> Co-authored-by: Bitnami Containers <bitnami-bot@vmware.com>
This commit is contained in:
committed by
GitHub
parent
665b3df147
commit
1f4a415b10
@@ -35,4 +35,4 @@ maintainers:
|
||||
name: jasperreports
|
||||
sources:
|
||||
- https://github.com/bitnami/charts/tree/main/bitnami/jasperreports
|
||||
version: 18.1.1
|
||||
version: 18.2.0
|
||||
|
||||
@@ -109,6 +109,7 @@ The command removes all the Kubernetes components associated with the chart and
|
||||
|
||||
| Name | Description | Value |
|
||||
| --------------------------------------------------- | ----------------------------------------------------------------------------------------- | -------------------------- |
|
||||
| `automountServiceAccountToken` | Mount Service Account token in pod | `false` |
|
||||
| `hostAliases` | Add deployment host aliases | `[]` |
|
||||
| `containerPorts.http` | HTTP port to expose at container level | `8080` |
|
||||
| `dnsConfig` | Pod DNS configuration. | `{}` |
|
||||
@@ -176,6 +177,10 @@ The command removes all the Kubernetes components associated with the chart and
|
||||
| `persistence.size` | PVC Storage Request for Jasperreports volume | `8Gi` |
|
||||
| `persistence.existingClaim` | An Existing PVC name for Jasperreports volume | `""` |
|
||||
| `persistence.annotations` | Persistent Volume Claim annotations | `{}` |
|
||||
| `serviceAccount.create` | Enable creation of ServiceAccount for JasperReports pod | `true` |
|
||||
| `serviceAccount.name` | The name of the ServiceAccount to use. | `""` |
|
||||
| `serviceAccount.automountServiceAccountToken` | Allows auto mount of ServiceAccountToken on the serviceAccount created | `false` |
|
||||
| `serviceAccount.annotations` | Additional custom annotations for the ServiceAccount | `{}` |
|
||||
|
||||
### Exposure parameters
|
||||
|
||||
|
||||
@@ -31,6 +31,17 @@ We truncate at 63 chars because some Kubernetes name fields are limited to this
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Create the name of the service account to use
|
||||
*/}}
|
||||
{{- define "jasperreports.serviceAccountName" -}}
|
||||
{{- if .Values.serviceAccount.create -}}
|
||||
{{ default (include "common.names.fullname" .) .Values.serviceAccount.name }}
|
||||
{{- else -}}
|
||||
{{ default "default" .Values.serviceAccount.name }}
|
||||
{{- end -}}
|
||||
{{- end -}}
|
||||
|
||||
{{/*
|
||||
Return the database Type
|
||||
*/}}
|
||||
|
||||
@@ -25,6 +25,8 @@ spec:
|
||||
{{- end }}
|
||||
spec:
|
||||
{{- include "jasperreports.imagePullSecrets" . | nindent 6 }}
|
||||
serviceAccountName: {{ include "jasperreports.serviceAccountName" .}}
|
||||
automountServiceAccountToken: {{ .Values.automountServiceAccountToken }}
|
||||
{{- if .Values.hostAliases }}
|
||||
hostAliases: {{- include "common.tplvalues.render" (dict "value" .Values.hostAliases "context" $) | nindent 8 }}
|
||||
{{- end }}
|
||||
|
||||
18
bitnami/jasperreports/templates/serviceaccount.yaml
Normal file
18
bitnami/jasperreports/templates/serviceaccount.yaml
Normal file
@@ -0,0 +1,18 @@
|
||||
{{- /*
|
||||
Copyright VMware, Inc.
|
||||
SPDX-License-Identifier: APACHE-2.0
|
||||
*/}}
|
||||
|
||||
{{- if .Values.serviceAccount.create -}}
|
||||
apiVersion: v1
|
||||
kind: ServiceAccount
|
||||
metadata:
|
||||
name: {{ include "jasperreports.serviceAccountName" . }}
|
||||
namespace: {{ .Release.Namespace | quote }}
|
||||
labels: {{- include "common.labels.standard" ( dict "customLabels" .Values.commonLabels "context" $ ) | nindent 4 }}
|
||||
{{- if or .Values.serviceAccount.annotations .Values.commonAnnotations }}
|
||||
{{- $annotations := include "common.tplvalues.merge" ( dict "values" ( list .Values.serviceAccount.annotations .Values.commonAnnotations ) "context" . ) }}
|
||||
annotations: {{- include "common.tplvalues.render" ( dict "value" $annotations "context" $) | nindent 4 }}
|
||||
{{- end }}
|
||||
automountServiceAccountToken: {{ .Values.serviceAccount.automountServiceAccountToken }}
|
||||
{{- end -}}
|
||||
@@ -142,6 +142,9 @@ updateStrategy:
|
||||
## @section Jasperreports deployment parameters
|
||||
##
|
||||
|
||||
## @param automountServiceAccountToken Mount Service Account token in pod
|
||||
##
|
||||
automountServiceAccountToken: false
|
||||
## @param hostAliases Add deployment host aliases
|
||||
## https://kubernetes.io/docs/concepts/services-networking/add-entries-to-pod-etc-hosts-with-host-aliases/
|
||||
##
|
||||
@@ -406,6 +409,25 @@ persistence:
|
||||
##
|
||||
annotations: {}
|
||||
|
||||
## Service Account
|
||||
## ref: https://kubernetes.io/docs/tasks/configure-pod-container/configure-service-account/
|
||||
##
|
||||
serviceAccount:
|
||||
## @param serviceAccount.create Enable creation of ServiceAccount for JasperReports pod
|
||||
##
|
||||
create: true
|
||||
## @param serviceAccount.name The name of the ServiceAccount to use.
|
||||
## If not set and create is true, a name is generated using the common.names.fullname template
|
||||
##
|
||||
name: ""
|
||||
## @param serviceAccount.automountServiceAccountToken Allows auto mount of ServiceAccountToken on the serviceAccount created
|
||||
## Can be set to false if pods using this serviceAccount do not need to use K8s API
|
||||
##
|
||||
automountServiceAccountToken: false
|
||||
## @param serviceAccount.annotations Additional custom annotations for the ServiceAccount
|
||||
##
|
||||
annotations: {}
|
||||
|
||||
## @section Exposure parameters
|
||||
##
|
||||
|
||||
|
||||
Reference in New Issue
Block a user