mirror of
https://github.com/minio/minio.git
synced 2025-11-26 20:38:20 -05:00
helm: adds support for policy conditions (#15599)
This commit is contained in:
@@ -12,6 +12,16 @@
|
||||
"Resource": [
|
||||
"{{ $statement.resources | join "\",\n\"" }}"
|
||||
]{{ end }}
|
||||
{{- if $statement.conditions }}
|
||||
{{- $condition_len := len $statement.conditions }}
|
||||
{{- $condition_len := sub $condition_len 1 }}
|
||||
,
|
||||
"Condition": {
|
||||
{{- range $k,$v := $statement.conditions }}
|
||||
{{- range $operator,$object := $v }}
|
||||
"{{ $operator }}": { {{ $object }} }{{- if lt $k $condition_len }},{{- end }}
|
||||
{{- end }}{{- end }}
|
||||
}{{- end }}
|
||||
}{{ if lt $i $statements_length }},{{end }}
|
||||
{{- end }}
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user