diff --git a/pkg/apis/litmuschaos/v1alpha1/chaosexperiment_types.go b/pkg/apis/litmuschaos/v1alpha1/chaosexperiment_types.go index 8017c7e08..ee909e504 100644 --- a/pkg/apis/litmuschaos/v1alpha1/chaosexperiment_types.go +++ b/pkg/apis/litmuschaos/v1alpha1/chaosexperiment_types.go @@ -41,7 +41,13 @@ type ChaosExperimentStatus struct { type ConfigMap struct { Data map[string]string `json:"data,omitempty"` Name string `json:"name"` - MountPath string `json:"mountpath"` + MountPath string `json:"mountPath"` +} + +// Secret is an simpler implementation of corev1.Secret +type Secret struct { + Name string `json:"name"` + MountPath string `json:"mountPath"` } // ExperimentDef defines information about nature of chaos & components subjected to it @@ -59,6 +65,8 @@ type ExperimentDef struct { Args []string `json:"args"` // ConfigMaps contains a list of ConfigMaps ConfigMaps []ConfigMap `json:"configmaps,omitempty"` + // Secrets contains a list of Secrets + Secrets []Secret `json:"secrets,omitempty"` } // ENVPair defines env var list to hold chaos params diff --git a/pkg/apis/litmuschaos/v1alpha1/zz_generated.deepcopy.go b/pkg/apis/litmuschaos/v1alpha1/zz_generated.deepcopy.go index 6fb257b85..44859911b 100644 --- a/pkg/apis/litmuschaos/v1alpha1/zz_generated.deepcopy.go +++ b/pkg/apis/litmuschaos/v1alpha1/zz_generated.deepcopy.go @@ -431,6 +431,11 @@ func (in *ExperimentDef) DeepCopyInto(out *ExperimentDef) { (*in)[i].DeepCopyInto(&(*out)[i]) } } + if in.Secrets != nil { + in, out := &in.Secrets, &out.Secrets + *out = make([]Secret, len(*in)) + copy(*out, *in) + } return } @@ -526,6 +531,22 @@ func (in *RunnerInfo) DeepCopy() *RunnerInfo { return out } +// DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. +func (in *Secret) DeepCopyInto(out *Secret) { + *out = *in + return +} + +// DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Secret. +func (in *Secret) DeepCopy() *Secret { + if in == nil { + return nil + } + out := new(Secret) + in.DeepCopyInto(out) + return out +} + // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. func (in *TestStatus) DeepCopyInto(out *TestStatus) { *out = *in