-
Notifications
You must be signed in to change notification settings - Fork 211
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: split helm chart template files (#1515)
* chore: split helm chart template files * chore: update trivy-operator static yaml Signed-off-by: chenk <[email protected]> * chore: update trivy-operator static yaml Signed-off-by: chenk <[email protected]> * chore: update trivy-operator static yaml Signed-off-by: chenk <[email protected]> * chore: update trivy-operator static yaml Signed-off-by: chenk <[email protected]> --------- Signed-off-by: chenk <[email protected]> Co-authored-by: chenk <[email protected]>
- Loading branch information
1 parent
8eaef68
commit 4f3a75a
Showing
23 changed files
with
526 additions
and
505 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
--- | ||
apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
name: trivy-operator | ||
namespace: {{ include "trivy-operator.namespace" . }} | ||
labels: {{- include "trivy-operator.labels" . | nindent 4 }} | ||
data: | ||
{{- with .Values.trivyOperator.scanJobTolerations }} | ||
scanJob.tolerations: {{ . | toJson | quote }} | ||
{{- end }} | ||
{{- with .Values.nodeCollector.volumes }} | ||
nodeCollector.volumes: {{ . | toJson | quote }} | ||
{{- end }} | ||
{{- with .Values.nodeCollector.volumeMounts }} | ||
nodeCollector.volumeMounts: {{ . | toJson | quote }} | ||
{{- end }} | ||
{{- with .Values.trivyOperator.scanJobAnnotations }} | ||
scanJob.annotations: {{ . | quote }} | ||
{{- end }} | ||
{{- with .Values.trivyOperator.scanJobAutomountServiceAccountToken }} | ||
scanJob.automountServiceAccountToken: {{ . | quote }} | ||
{{- end }} | ||
{{- with .Values.trivyOperator.skipInitContainers }} | ||
scanJob.skipInitContainers: {{ . | quote }} | ||
{{- end }} | ||
{{- with .Values.nodeCollector.excludeNodes }} | ||
nodeCollector.excludeNodes: {{ . | quote }} | ||
{{- end }} | ||
{{- with .Values.trivyOperator.scanJobPodTemplateLabels }} | ||
scanJob.podTemplateLabels: {{ . | quote }} | ||
{{- end }} | ||
{{- with .Values.trivyOperator.additionalReportLabels }} | ||
report.additionalLabels: {{ . | quote }} | ||
{{- end }} | ||
{{- with .Values.trivyOperator.scanJobNodeSelector }} | ||
scanJob.nodeSelector: {{ . | toJson | quote }} | ||
{{- end }} | ||
{{- with .Values.trivyOperator.scanJobPodTemplatePodSecurityContext }} | ||
scanJob.podTemplatePodSecurityContext: {{ . | toJson | quote }} | ||
{{- end }} | ||
{{- with .Values.trivyOperator.scanJobPodTemplateContainerSecurityContext }} | ||
scanJob.podTemplateContainerSecurityContext: {{ . | toJson | quote }} | ||
{{- end }} | ||
{{- with .Values.trivyOperator.scanJobPodPriorityClassName }} | ||
scanJob.podPriorityClassName: {{ . | quote }} | ||
{{- end }} | ||
{{- with .Values.trivyOperator.scanJobCompressLogs }} | ||
scanJob.compressLogs: {{ . | toJson | quote }} | ||
{{- end }} | ||
{{- if or .Values.operator.vulnerabilityScannerEnabled .Values.operator.exposedSecretScannerEnabled .Values.operator.scannerReportTTL }} | ||
vulnerabilityReports.scanner: {{ .Values.trivyOperator.vulnerabilityReportsPlugin | quote }} | ||
{{- end }} | ||
{{- if .Values.operator.configAuditScannerEnabled }} | ||
configAuditReports.scanner: {{ .Values.trivyOperator.configAuditReportsPlugin | quote }} | ||
{{- end }} | ||
{{- if .Values.operator.clusterComplianceEnabled }} | ||
compliance.failEntriesLimit: {{ required ".Values.compliance.failEntriesLimit is required" .Values.compliance.failEntriesLimit | quote }} | ||
{{- end }} | ||
{{- with .Values.trivyOperator.reportResourceLabels }} | ||
report.resourceLabels: {{ . | quote }} | ||
metrics.resourceLabelsPrefix: {{ $.Values.trivyOperator.metricsResourceLabelsPrefix | quote }} | ||
{{- end }} | ||
{{- with .Values.trivyOperator.reportRecordFailedChecksOnly }} | ||
report.recordFailedChecksOnly: {{ . | quote }} | ||
{{- end }} | ||
{{- with .Values.trivyOperator.skipResourceByLabels }} | ||
skipResourceByLabels: {{ . | quote }} | ||
{{- end }} | ||
{{- if .Values.operator.builtInTrivyServer }} | ||
trivy.serverURL: {{ printf "http://%s.%s:%s" .Values.trivy.serverServiceName (include "trivy-operator.namespace" .) "4954" | quote }} | ||
{{- end }} | ||
node.collector.imageRef: "{{ .Values.nodeCollector.registry }}/{{ .Values.nodeCollector.repository }}:{{ .Values.nodeCollector.tag }}" | ||
{{- with .Values.nodeCollector.imagePullSecret }} | ||
node.collector.imagePullSecret: "{{ . }}" | ||
{{- end }} |
1 change: 0 additions & 1 deletion
1
deploy/helm/templates/policies.yaml → ...y/helm/templates/configmaps/policies.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,3 @@ | ||
--- | ||
apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{{- if .Values.rbac.create }} | ||
{{ .Files.Get "generated/role.yaml" }} | ||
|
||
{{- if .Values.operator.accessGlobalSecretsAndServiceAccount -}} | ||
- apiGroups: | ||
- "" | ||
resources: | ||
- secrets | ||
verbs: | ||
- create | ||
- get | ||
- update | ||
- apiGroups: | ||
- "" | ||
resources: | ||
- serviceaccounts | ||
verbs: | ||
- get | ||
{{- end }} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
{{- if .Values.rbac.create }} | ||
apiVersion: rbac.authorization.k8s.io/v1 | ||
kind: ClusterRoleBinding | ||
metadata: | ||
name: {{ include "trivy-operator.fullname" . }} | ||
labels: {{- include "trivy-operator.labels" . | nindent 4 }} | ||
roleRef: | ||
apiGroup: rbac.authorization.k8s.io | ||
kind: ClusterRole | ||
name: trivy-operator | ||
subjects: | ||
- kind: ServiceAccount | ||
name: {{ include "trivy-operator.serviceAccountName" . }} | ||
namespace: {{ include "trivy-operator.namespace" . }} | ||
{{- end }} |
Oops, something went wrong.