I'm trying to create this associative array, but it throws an error because of the volumeClaimTemplates[0]
This is my code:
declare -A example=(["'spec.statefulSet.spec.volumeClaimTemplates[0].spec'"]="TEST")
This is the error:
['spec.statefulSet.spec.volumeClaimTemplates[0].spec']=TEST: bad array subscript
If I remove the [0] from the volumeClaimTemplates then I get no errors.
Got it to work like this