@@ -52,20 +52,20 @@ func CreateCustomConfigSecret(namespace string, name string, contents map[string
5252 )
5353}
5454
55- func GetDefaultBarbicanSpec () map [string ]interface {} {
56- return map [string ]interface {} {
55+ func GetDefaultBarbicanSpec () map [string ]any {
56+ return map [string ]any {
5757 "databaseInstance" : "openstack" ,
5858 "secret" : SecretName ,
5959 "simpleCryptoBackendSecret" : SecretName ,
6060 "customServiceConfig" : barbicanTest .BaseCustomServiceConfig ,
6161 }
6262}
6363
64- func CreateBarbican (name types.NamespacedName , spec map [string ]interface {} ) client.Object {
65- raw := map [string ]interface {} {
64+ func CreateBarbican (name types.NamespacedName , spec map [string ]any ) client.Object {
65+ raw := map [string ]any {
6666 "apiVersion" : "barbican.openstack.org/v1beta1" ,
6767 "kind" : "Barbican" ,
68- "metadata" : map [string ]interface {} {
68+ "metadata" : map [string ]any {
6969 "name" : name .Name ,
7070 "namespace" : name .Namespace ,
7171 },
@@ -86,7 +86,7 @@ func CreateBarbicanMessageBusSecret(namespace string, name string) *corev1.Secre
8686 s := th .CreateSecret (
8787 types.NamespacedName {Namespace : namespace , Name : name },
8888 map [string ][]byte {
89- "transport_url" : [] byte ( fmt .Sprintf ( "rabbit://%s/fake" , name ) ),
89+ "transport_url" : fmt .Appendf ( nil , "rabbit://%s/fake" , name ),
9090 },
9191 )
9292 logger .Info ("Secret created" , "name" , name )
@@ -181,8 +181,8 @@ func BarbicanWorkerConditionGetter(name types.NamespacedName) condition.Conditio
181181}
182182
183183// ========== TLS Stuff ==============
184- func GetTLSBarbicanSpec () map [string ]interface {} {
185- return map [string ]interface {} {
184+ func GetTLSBarbicanSpec () map [string ]any {
185+ return map [string ]any {
186186 "databaseInstance" : "openstack" ,
187187 "secret" : SecretName ,
188188 "simpleCryptoBackendSecret" : SecretName ,
@@ -192,15 +192,15 @@ func GetTLSBarbicanSpec() map[string]interface{} {
192192 }
193193}
194194
195- func GetTLSBarbicanAPISpec () map [string ]interface {} {
195+ func GetTLSBarbicanAPISpec () map [string ]any {
196196 spec := GetDefaultBarbicanAPISpec ()
197- maps .Copy (spec , map [string ]interface {} {
198- "tls" : map [string ]interface {} {
199- "api" : map [string ]interface {} {
200- "internal" : map [string ]interface {} {
197+ maps .Copy (spec , map [string ]any {
198+ "tls" : map [string ]any {
199+ "api" : map [string ]any {
200+ "internal" : map [string ]any {
201201 "secretName" : InternalCertSecretName ,
202202 },
203- "public" : map [string ]interface {} {
203+ "public" : map [string ]any {
204204 "secretName" : PublicCertSecretName ,
205205 },
206206 },
@@ -231,13 +231,13 @@ key_wrap_generate_iv = true
231231always_set_cka_sensitive = true
232232os_locking_ok = false`
233233
234- func GetPKCS11BarbicanSpec () map [string ]interface {} {
234+ func GetPKCS11BarbicanSpec () map [string ]any {
235235 spec := GetDefaultBarbicanSpec ()
236- maps .Copy (spec , map [string ]interface {} {
236+ maps .Copy (spec , map [string ]any {
237237 "customServiceConfig" : PKCS11CustomData ,
238238 "enabledSecretStores" : []string {"pkcs11" },
239239 "globalDefaultSecretStore" : "pkcs11" ,
240- "pkcs11" : map [string ]interface {} {
240+ "pkcs11" : map [string ]any {
241241 "clientDataPath" : PKCS11ClientDataPath ,
242242 "loginSecret" : PKCS11LoginSecret ,
243243 "clientDataSecret" : PKCS11ClientDataSecret ,
@@ -246,7 +246,7 @@ func GetPKCS11BarbicanSpec() map[string]interface{} {
246246 return spec
247247}
248248
249- func GetPKCS11BarbicanAPISpec () map [string ]interface {} {
249+ func GetPKCS11BarbicanAPISpec () map [string ]any {
250250 spec := GetPKCS11BarbicanSpec ()
251251 maps .Copy (spec , GetDefaultBarbicanAPISpec ())
252252 return spec
@@ -276,8 +276,8 @@ func CreatePKCS11ClientDataSecret(namespace string, name string) *corev1.Secret
276276
277277// ========== End of PKCS11 Stuff ============
278278
279- func GetDefaultBarbicanAPISpec () map [string ]interface {} {
280- return map [string ]interface {} {
279+ func GetDefaultBarbicanAPISpec () map [string ]any {
280+ return map [string ]any {
281281 "secret" : SecretName ,
282282 "simpleCryptoBackendSecret" : SecretName ,
283283 "replicas" : 1 ,
@@ -291,13 +291,13 @@ func GetDefaultBarbicanAPISpec() map[string]interface{} {
291291 }
292292}
293293
294- func CreateBarbicanAPI (name types.NamespacedName , spec map [string ]interface {} ) client.Object {
294+ func CreateBarbicanAPI (name types.NamespacedName , spec map [string ]any ) client.Object {
295295 // we get the parent CR and set ownership to the barbicanAPI CR
296- raw := map [string ]interface {} {
296+ raw := map [string ]any {
297297 "apiVersion" : "barbican.openstack.org/v1beta1" ,
298298 "kind" : "BarbicanAPI" ,
299- "metadata" : map [string ]interface {} {
300- "annotations" : map [string ]interface {} {
299+ "metadata" : map [string ]any {
300+ "annotations" : map [string ]any {
301301 "keystoneEndpoint" : "true" ,
302302 },
303303 "name" : name .Name ,
@@ -346,16 +346,16 @@ func GetBarbicanWorkerSpec(name types.NamespacedName) barbicanv1.BarbicanWorkerT
346346// multi AZ, which is not applicable in this context
347347func GetSampleTopologySpec (
348348 label string ,
349- ) (map [string ]interface {} , []corev1.TopologySpreadConstraint ) {
349+ ) (map [string ]any , []corev1.TopologySpreadConstraint ) {
350350 // Build the topology Spec
351- topologySpec := map [string ]interface {} {
352- "topologySpreadConstraints" : []map [string ]interface {} {
351+ topologySpec := map [string ]any {
352+ "topologySpreadConstraints" : []map [string ]any {
353353 {
354354 "maxSkew" : 1 ,
355355 "topologyKey" : corev1 .LabelHostname ,
356356 "whenUnsatisfiable" : "ScheduleAnyway" ,
357- "labelSelector" : map [string ]interface {} {
358- "matchLabels" : map [string ]interface {} {
357+ "labelSelector" : map [string ]any {
358+ "matchLabels" : map [string ]any {
359359 "component" : label ,
360360 },
361361 },
0 commit comments