diff --git a/PROJECT b/PROJECT index 5aeaddb4..a20c86e5 100644 --- a/PROJECT +++ b/PROJECT @@ -425,4 +425,4 @@ resources: defaulting: true validation: true webhookVersion: v1 -version: "3" +version: "3" \ No newline at end of file diff --git a/api/v1alpha1/webhook_suite_test.go b/api/v1alpha1/webhook_suite_test.go index b06d4e3d..bac11893 100644 --- a/api/v1alpha1/webhook_suite_test.go +++ b/api/v1alpha1/webhook_suite_test.go @@ -235,7 +235,7 @@ var _ = BeforeSuite(func() { Expect(err).NotTo(HaveOccurred()) err = (&GCPAuthEngineConfig{}).SetupWebhookWithManager(mgr) - Expect(err).NotTo(HaveOccurred()) + Expect(err).NotTo(HaveOccurred()) err = (&GCPAuthEngineRole{}).SetupWebhookWithManager(mgr) Expect(err).NotTo(HaveOccurred()) diff --git a/api/v1alpha1/zz_generated.deepcopy.go b/api/v1alpha1/zz_generated.deepcopy.go index 2a68174b..b1b53a93 100644 --- a/api/v1alpha1/zz_generated.deepcopy.go +++ b/api/v1alpha1/zz_generated.deepcopy.go @@ -1219,6 +1219,7 @@ func (in *GCPAuthEngineRoleStatus) DeepCopy() *GCPAuthEngineRoleStatus { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. + func (in *GCPConfig) DeepCopyInto(out *GCPConfig) { *out = *in if in.CustomEndpoint != nil { @@ -1239,6 +1240,7 @@ func (in *GCPConfig) DeepCopy() *GCPConfig { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. + func (in *GCPRole) DeepCopyInto(out *GCPRole) { *out = *in if in.BoundServiceAccounts != nil { @@ -1299,6 +1301,7 @@ func (in *GCPRole) DeepCopy() *GCPRole { } // DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil. + func (in *GHConfig) DeepCopyInto(out *GHConfig) { *out = *in } diff --git a/config/samples/kustomization.yaml b/config/samples/kustomization.yaml index f9d8e876..1a5de839 100644 --- a/config/samples/kustomization.yaml +++ b/config/samples/kustomization.yaml @@ -32,5 +32,4 @@ resources: - redhatcop_v1alpha1_azureauthenginerole.yaml - redhatcop_v1alpha1_gcpauthengineconfig.yaml - redhatcop_v1alpha1_gcpauthenginerole.yaml - #+kubebuilder:scaffold:manifestskustomizesamples diff --git a/docs/auth-engines.md b/docs/auth-engines.md index 13c6c402..f4c131e0 100644 --- a/docs/auth-engines.md +++ b/docs/auth-engines.md @@ -492,7 +492,6 @@ spec: The endpoint value provided for a given key has the form of scheme://host:port. The scheme:// and :port portions of the endpoint value are optional. - ## GCPAuthEngineRole The `GCPAuthEngineRole` CRD allows a user to register a role in an authentication engine mount of type [Google Cloud](https://developer.hashicorp.com/vault/api-docs/auth/gcp#create-update-role). diff --git a/main.go b/main.go index 7d0e6aca..a5f79f4f 100644 --- a/main.go +++ b/main.go @@ -165,10 +165,12 @@ func main() { setupLog.Error(err, "unable to create controller", "controller", "GCPAuthEngineConfig") os.Exit(1) } + if err = (&controllers.GCPAuthEngineRoleReconciler{ReconcilerBase: vaultresourcecontroller.NewFromManager(mgr, "GCPAuthEngineRole")}).SetupWithManager(mgr); err != nil { setupLog.Error(err, "unable to create controller", "controller", "GCPAuthEngineRole") os.Exit(1) } + if err = (&controllers.VaultSecretReconciler{ReconcilerBase: vaultresourcecontroller.NewFromManager(mgr, "VaultSecret")}).SetupWithManager(mgr); err != nil { setupLog.Error(err, "unable to create controller", "controller", "VaultSecret") os.Exit(1) @@ -307,6 +309,7 @@ func main() { setupLog.Error(err, "unable to create webhook", "webhook", "GCPAuthEngineConfig") os.Exit(1) } + if err = (&redhatcopv1alpha1.GCPAuthEngineRole{}).SetupWebhookWithManager(mgr); err != nil { setupLog.Error(err, "unable to create webhook", "webhook", "GCPAuthEngineRole") os.Exit(1)