diff --git a/apis/cloud/v1alpha1/zz_generated.deepcopy.go b/apis/cloud/v1alpha1/zz_generated.deepcopy.go index 5cf63bd..e5e168f 100644 --- a/apis/cloud/v1alpha1/zz_generated.deepcopy.go +++ b/apis/cloud/v1alpha1/zz_generated.deepcopy.go @@ -9,7 +9,7 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( - v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" + "github.com/crossplane/crossplane-runtime/apis/common/v1" runtime "k8s.io/apimachinery/pkg/runtime" ) diff --git a/apis/cloud/v1alpha1/zz_generated.resolvers.go b/apis/cloud/v1alpha1/zz_generated.resolvers.go index 0634453..3edc426 100644 --- a/apis/cloud/v1alpha1/zz_generated.resolvers.go +++ b/apis/cloud/v1alpha1/zz_generated.resolvers.go @@ -7,7 +7,6 @@ package v1alpha1 import ( "context" - reference "github.com/crossplane/crossplane-runtime/pkg/reference" errors "github.com/pkg/errors" client "sigs.k8s.io/controller-runtime/pkg/client" diff --git a/apis/databases/v1alpha1/zz_generated.deepcopy.go b/apis/databases/v1alpha1/zz_generated.deepcopy.go index d7ef0cf..b938f69 100644 --- a/apis/databases/v1alpha1/zz_generated.deepcopy.go +++ b/apis/databases/v1alpha1/zz_generated.deepcopy.go @@ -9,6 +9,7 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( + "github.com/crossplane/crossplane-runtime/apis/common/v1" runtime "k8s.io/apimachinery/pkg/runtime" ) @@ -404,6 +405,16 @@ func (in *ProjectDatabaseDatabaseInitParameters) DeepCopyInto(out *ProjectDataba *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Engine != nil { in, out := &in.Engine, &out.Engine *out = new(string) @@ -516,6 +527,16 @@ func (in *ProjectDatabaseDatabaseParameters) DeepCopyInto(out *ProjectDatabaseDa *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Engine != nil { in, out := &in.Engine, &out.Engine *out = new(string) @@ -613,6 +634,16 @@ func (in *ProjectDatabaseIPRestrictionInitParameters) DeepCopyInto(out *ProjectD *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Description != nil { in, out := &in.Description, &out.Description *out = new(string) @@ -735,6 +766,16 @@ func (in *ProjectDatabaseIPRestrictionParameters) DeepCopyInto(out *ProjectDatab *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Description != nil { in, out := &in.Description, &out.Description *out = new(string) @@ -948,6 +989,16 @@ func (in *ProjectDatabaseIntegrationInitParameters) DeepCopyInto(out *ProjectDat *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.DestinationServiceID != nil { in, out := &in.DestinationServiceID, &out.DestinationServiceID *out = new(string) @@ -1112,6 +1163,16 @@ func (in *ProjectDatabaseIntegrationParameters) DeepCopyInto(out *ProjectDatabas *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.DestinationServiceID != nil { in, out := &in.DestinationServiceID, &out.DestinationServiceID *out = new(string) @@ -1235,6 +1296,16 @@ func (in *ProjectDatabaseKafkaACLInitParameters) DeepCopyInto(out *ProjectDataba *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Permission != nil { in, out := &in.Permission, &out.Permission *out = new(string) @@ -1352,6 +1423,16 @@ func (in *ProjectDatabaseKafkaACLParameters) DeepCopyInto(out *ProjectDatabaseKa *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Permission != nil { in, out := &in.Permission, &out.Permission *out = new(string) @@ -1454,6 +1535,16 @@ func (in *ProjectDatabaseKafkaSchemaregistryaclInitParameters) DeepCopyInto(out *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Permission != nil { in, out := &in.Permission, &out.Permission *out = new(string) @@ -1571,6 +1662,16 @@ func (in *ProjectDatabaseKafkaSchemaregistryaclParameters) DeepCopyInto(out *Pro *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Permission != nil { in, out := &in.Permission, &out.Permission *out = new(string) @@ -1673,6 +1774,16 @@ func (in *ProjectDatabaseKafkaTopicInitParameters) DeepCopyInto(out *ProjectData *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.MinInsyncReplicas != nil { in, out := &in.MinInsyncReplicas, &out.MinInsyncReplicas *out = new(float64) @@ -1820,6 +1931,16 @@ func (in *ProjectDatabaseKafkaTopicParameters) DeepCopyInto(out *ProjectDatabase *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.MinInsyncReplicas != nil { in, out := &in.MinInsyncReplicas, &out.MinInsyncReplicas *out = new(float64) @@ -1969,6 +2090,16 @@ func (in *ProjectDatabaseM3DbNamespaceInitParameters) DeepCopyInto(out *ProjectD *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Name != nil { in, out := &in.Name, &out.Name *out = new(string) @@ -2151,6 +2282,16 @@ func (in *ProjectDatabaseM3DbNamespaceParameters) DeepCopyInto(out *ProjectDatab *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Name != nil { in, out := &in.Name, &out.Name *out = new(string) @@ -2283,6 +2424,16 @@ func (in *ProjectDatabaseM3DbUserInitParameters) DeepCopyInto(out *ProjectDataba *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Group != nil { in, out := &in.Group, &out.Group *out = new(string) @@ -2410,6 +2561,16 @@ func (in *ProjectDatabaseM3DbUserParameters) DeepCopyInto(out *ProjectDatabaseM3 *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Group != nil { in, out := &in.Group, &out.Group *out = new(string) @@ -2512,6 +2673,16 @@ func (in *ProjectDatabaseMongodbUserInitParameters) DeepCopyInto(out *ProjectDat *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Name != nil { in, out := &in.Name, &out.Name *out = new(string) @@ -2651,6 +2822,16 @@ func (in *ProjectDatabaseMongodbUserParameters) DeepCopyInto(out *ProjectDatabas *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Name != nil { in, out := &in.Name, &out.Name *out = new(string) @@ -2907,6 +3088,16 @@ func (in *ProjectDatabaseOpensearchPatternInitParameters) DeepCopyInto(out *Proj *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.MaxIndexCount != nil { in, out := &in.MaxIndexCount, &out.MaxIndexCount *out = new(float64) @@ -3014,6 +3205,16 @@ func (in *ProjectDatabaseOpensearchPatternParameters) DeepCopyInto(out *ProjectD *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.MaxIndexCount != nil { in, out := &in.MaxIndexCount, &out.MaxIndexCount *out = new(float64) @@ -3118,6 +3319,16 @@ func (in *ProjectDatabaseOpensearchUserInitParameters) DeepCopyInto(out *Project *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Name != nil { in, out := &in.Name, &out.Name *out = new(string) @@ -3249,6 +3460,16 @@ func (in *ProjectDatabaseOpensearchUserParameters) DeepCopyInto(out *ProjectData *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Name != nil { in, out := &in.Name, &out.Name *out = new(string) @@ -3457,6 +3678,16 @@ func (in *ProjectDatabasePostgresqlConnectionPoolInitParameters) DeepCopyInto(ou *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.DatabaseID != nil { in, out := &in.DatabaseID, &out.DatabaseID *out = new(string) @@ -3609,6 +3840,16 @@ func (in *ProjectDatabasePostgresqlConnectionPoolParameters) DeepCopyInto(out *P *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.DatabaseID != nil { in, out := &in.DatabaseID, &out.DatabaseID *out = new(string) @@ -3721,6 +3962,16 @@ func (in *ProjectDatabasePostgresqlUserInitParameters) DeepCopyInto(out *Project *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Name != nil { in, out := &in.Name, &out.Name *out = new(string) @@ -3860,6 +4111,16 @@ func (in *ProjectDatabasePostgresqlUserParameters) DeepCopyInto(out *ProjectData *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Name != nil { in, out := &in.Name, &out.Name *out = new(string) @@ -3990,6 +4251,16 @@ func (in *ProjectDatabaseRedisUserInitParameters) DeepCopyInto(out *ProjectDatab *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Commands != nil { in, out := &in.Commands, &out.Commands *out = make([]*string, len(*in)) @@ -4195,6 +4466,16 @@ func (in *ProjectDatabaseRedisUserParameters) DeepCopyInto(out *ProjectDatabaseR *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Commands != nil { in, out := &in.Commands, &out.Commands *out = make([]*string, len(*in)) @@ -4349,6 +4630,16 @@ func (in *ProjectDatabaseUserInitParameters) DeepCopyInto(out *ProjectDatabaseUs *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Engine != nil { in, out := &in.Engine, &out.Engine *out = new(string) @@ -4476,6 +4767,16 @@ func (in *ProjectDatabaseUserParameters) DeepCopyInto(out *ProjectDatabaseUserPa *out = new(string) **out = **in } + if in.ClusterIDRef != nil { + in, out := &in.ClusterIDRef, &out.ClusterIDRef + *out = new(v1.Reference) + (*in).DeepCopyInto(*out) + } + if in.ClusterIDSelector != nil { + in, out := &in.ClusterIDSelector, &out.ClusterIDSelector + *out = new(v1.Selector) + (*in).DeepCopyInto(*out) + } if in.Engine != nil { in, out := &in.Engine, &out.Engine *out = new(string) diff --git a/apis/databases/v1alpha1/zz_generated.resolvers.go b/apis/databases/v1alpha1/zz_generated.resolvers.go new file mode 100644 index 0000000..0c75d64 --- /dev/null +++ b/apis/databases/v1alpha1/zz_generated.resolvers.go @@ -0,0 +1,643 @@ +/* +Copyright 2022 Upbound Inc. +*/ +// Code generated by angryjet. DO NOT EDIT. + +package v1alpha1 + +import ( + "context" + reference "github.com/crossplane/crossplane-runtime/pkg/reference" + errors "github.com/pkg/errors" + client "sigs.k8s.io/controller-runtime/pkg/client" +) + +// ResolveReferences of this ProjectDatabaseDatabase. +func (mg *ProjectDatabaseDatabase) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} + +// ResolveReferences of this ProjectDatabaseIPRestriction. +func (mg *ProjectDatabaseIPRestriction) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} + +// ResolveReferences of this ProjectDatabaseIntegration. +func (mg *ProjectDatabaseIntegration) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} + +// ResolveReferences of this ProjectDatabaseKafkaACL. +func (mg *ProjectDatabaseKafkaACL) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} + +// ResolveReferences of this ProjectDatabaseKafkaSchemaregistryacl. +func (mg *ProjectDatabaseKafkaSchemaregistryacl) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} + +// ResolveReferences of this ProjectDatabaseKafkaTopic. +func (mg *ProjectDatabaseKafkaTopic) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} + +// ResolveReferences of this ProjectDatabaseM3DbNamespace. +func (mg *ProjectDatabaseM3DbNamespace) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} + +// ResolveReferences of this ProjectDatabaseM3DbUser. +func (mg *ProjectDatabaseM3DbUser) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} + +// ResolveReferences of this ProjectDatabaseMongodbUser. +func (mg *ProjectDatabaseMongodbUser) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} + +// ResolveReferences of this ProjectDatabaseOpensearchPattern. +func (mg *ProjectDatabaseOpensearchPattern) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} + +// ResolveReferences of this ProjectDatabaseOpensearchUser. +func (mg *ProjectDatabaseOpensearchUser) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} + +// ResolveReferences of this ProjectDatabasePostgresqlConnectionPool. +func (mg *ProjectDatabasePostgresqlConnectionPool) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} + +// ResolveReferences of this ProjectDatabasePostgresqlUser. +func (mg *ProjectDatabasePostgresqlUser) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} + +// ResolveReferences of this ProjectDatabaseRedisUser. +func (mg *ProjectDatabaseRedisUser) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} + +// ResolveReferences of this ProjectDatabaseUser. +func (mg *ProjectDatabaseUser) ResolveReferences(ctx context.Context, c client.Reader) error { + r := reference.NewAPIResolver(c, mg) + + var rsp reference.ResolutionResponse + var err error + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.ForProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.ForProvider.ClusterIDRef, + Selector: mg.Spec.ForProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.ForProvider.ClusterID") + } + mg.Spec.ForProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.ForProvider.ClusterIDRef = rsp.ResolvedReference + + rsp, err = r.Resolve(ctx, reference.ResolutionRequest{ + CurrentValue: reference.FromPtrValue(mg.Spec.InitProvider.ClusterID), + Extract: reference.ExternalName(), + Reference: mg.Spec.InitProvider.ClusterIDRef, + Selector: mg.Spec.InitProvider.ClusterIDSelector, + To: reference.To{ + List: &ProjectDatabaseList{}, + Managed: &ProjectDatabase{}, + }, + }) + if err != nil { + return errors.Wrap(err, "mg.Spec.InitProvider.ClusterID") + } + mg.Spec.InitProvider.ClusterID = reference.ToPtrValue(rsp.ResolvedValue) + mg.Spec.InitProvider.ClusterIDRef = rsp.ResolvedReference + + return nil +} diff --git a/apis/databases/v1alpha1/zz_projectdatabasedatabase_types.go b/apis/databases/v1alpha1/zz_projectdatabasedatabase_types.go index c74aa76..0151b2b 100755 --- a/apis/databases/v1alpha1/zz_projectdatabasedatabase_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabasedatabase_types.go @@ -16,8 +16,17 @@ import ( type ProjectDatabaseDatabaseInitParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Name of the engine of the service Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` @@ -49,9 +58,18 @@ type ProjectDatabaseDatabaseObservation struct { type ProjectDatabaseDatabaseParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Name of the engine of the service // +kubebuilder:validation:Optional Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` @@ -100,7 +118,6 @@ type ProjectDatabaseDatabaseStatus struct { type ProjectDatabaseDatabase struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.engine) || (has(self.initProvider) && has(self.initProvider.engine))",message="spec.forProvider.engine is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.name) || (has(self.initProvider) && has(self.initProvider.name))",message="spec.forProvider.name is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serviceName) || (has(self.initProvider) && has(self.initProvider.serviceName))",message="spec.forProvider.serviceName is a required parameter" diff --git a/apis/databases/v1alpha1/zz_projectdatabaseintegration_types.go b/apis/databases/v1alpha1/zz_projectdatabaseintegration_types.go index 01696f4..5d409d2 100755 --- a/apis/databases/v1alpha1/zz_projectdatabaseintegration_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabaseintegration_types.go @@ -16,8 +16,17 @@ import ( type ProjectDatabaseIntegrationInitParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // ID of the destination service DestinationServiceID *string `json:"destinationServiceId,omitempty" tf:"destination_service_id,omitempty"` @@ -69,9 +78,18 @@ type ProjectDatabaseIntegrationObservation struct { type ProjectDatabaseIntegrationParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // ID of the destination service // +kubebuilder:validation:Optional DestinationServiceID *string `json:"destinationServiceId,omitempty" tf:"destination_service_id,omitempty"` @@ -133,7 +151,6 @@ type ProjectDatabaseIntegrationStatus struct { type ProjectDatabaseIntegration struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.destinationServiceId) || (has(self.initProvider) && has(self.initProvider.destinationServiceId))",message="spec.forProvider.destinationServiceId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.engine) || (has(self.initProvider) && has(self.initProvider.engine))",message="spec.forProvider.engine is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serviceName) || (has(self.initProvider) && has(self.initProvider.serviceName))",message="spec.forProvider.serviceName is a required parameter" diff --git a/apis/databases/v1alpha1/zz_projectdatabaseiprestriction_types.go b/apis/databases/v1alpha1/zz_projectdatabaseiprestriction_types.go index c52094c..4682272 100755 --- a/apis/databases/v1alpha1/zz_projectdatabaseiprestriction_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabaseiprestriction_types.go @@ -16,8 +16,17 @@ import ( type ProjectDatabaseIPRestrictionInitParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Description of the IP restriction Description *string `json:"description,omitempty" tf:"description,omitempty"` @@ -55,9 +64,18 @@ type ProjectDatabaseIPRestrictionObservation struct { type ProjectDatabaseIPRestrictionParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Description of the IP restriction // +kubebuilder:validation:Optional Description *string `json:"description,omitempty" tf:"description,omitempty"` @@ -110,7 +128,6 @@ type ProjectDatabaseIPRestrictionStatus struct { type ProjectDatabaseIPRestriction struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.engine) || (has(self.initProvider) && has(self.initProvider.engine))",message="spec.forProvider.engine is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.ip) || (has(self.initProvider) && has(self.initProvider.ip))",message="spec.forProvider.ip is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serviceName) || (has(self.initProvider) && has(self.initProvider.serviceName))",message="spec.forProvider.serviceName is a required parameter" diff --git a/apis/databases/v1alpha1/zz_projectdatabasekafkaacl_types.go b/apis/databases/v1alpha1/zz_projectdatabasekafkaacl_types.go index d623d5d..4c71e88 100755 --- a/apis/databases/v1alpha1/zz_projectdatabasekafkaacl_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabasekafkaacl_types.go @@ -16,8 +16,17 @@ import ( type ProjectDatabaseKafkaACLInitParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Permission to give to this username on this topic Permission *string `json:"permission,omitempty" tf:"permission,omitempty"` @@ -52,9 +61,18 @@ type ProjectDatabaseKafkaACLObservation struct { type ProjectDatabaseKafkaACLParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Permission to give to this username on this topic // +kubebuilder:validation:Optional Permission *string `json:"permission,omitempty" tf:"permission,omitempty"` @@ -107,7 +125,6 @@ type ProjectDatabaseKafkaACLStatus struct { type ProjectDatabaseKafkaACL struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.permission) || (has(self.initProvider) && has(self.initProvider.permission))",message="spec.forProvider.permission is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serviceName) || (has(self.initProvider) && has(self.initProvider.serviceName))",message="spec.forProvider.serviceName is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.topic) || (has(self.initProvider) && has(self.initProvider.topic))",message="spec.forProvider.topic is a required parameter" diff --git a/apis/databases/v1alpha1/zz_projectdatabasekafkaschemaregistryacl_types.go b/apis/databases/v1alpha1/zz_projectdatabasekafkaschemaregistryacl_types.go index 43e3783..125f5fe 100755 --- a/apis/databases/v1alpha1/zz_projectdatabasekafkaschemaregistryacl_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabasekafkaschemaregistryacl_types.go @@ -16,8 +16,17 @@ import ( type ProjectDatabaseKafkaSchemaregistryaclInitParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Permission to give to this username on this resource Permission *string `json:"permission,omitempty" tf:"permission,omitempty"` @@ -52,9 +61,18 @@ type ProjectDatabaseKafkaSchemaregistryaclObservation struct { type ProjectDatabaseKafkaSchemaregistryaclParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Permission to give to this username on this resource // +kubebuilder:validation:Optional Permission *string `json:"permission,omitempty" tf:"permission,omitempty"` @@ -107,7 +125,6 @@ type ProjectDatabaseKafkaSchemaregistryaclStatus struct { type ProjectDatabaseKafkaSchemaregistryacl struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.permission) || (has(self.initProvider) && has(self.initProvider.permission))",message="spec.forProvider.permission is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.resource) || (has(self.initProvider) && has(self.initProvider.resource))",message="spec.forProvider.resource is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serviceName) || (has(self.initProvider) && has(self.initProvider.serviceName))",message="spec.forProvider.serviceName is a required parameter" diff --git a/apis/databases/v1alpha1/zz_projectdatabasekafkatopic_types.go b/apis/databases/v1alpha1/zz_projectdatabasekafkatopic_types.go index d2b31a5..34166e2 100755 --- a/apis/databases/v1alpha1/zz_projectdatabasekafkatopic_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabasekafkatopic_types.go @@ -16,8 +16,17 @@ import ( type ProjectDatabaseKafkaTopicInitParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Minimum insync replica accepted for this topic MinInsyncReplicas *float64 `json:"minInsyncReplicas,omitempty" tf:"min_insync_replicas,omitempty"` @@ -70,9 +79,18 @@ type ProjectDatabaseKafkaTopicObservation struct { type ProjectDatabaseKafkaTopicParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Minimum insync replica accepted for this topic // +kubebuilder:validation:Optional MinInsyncReplicas *float64 `json:"minInsyncReplicas,omitempty" tf:"min_insync_replicas,omitempty"` @@ -137,7 +155,6 @@ type ProjectDatabaseKafkaTopicStatus struct { type ProjectDatabaseKafkaTopic struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.name) || (has(self.initProvider) && has(self.initProvider.name))",message="spec.forProvider.name is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serviceName) || (has(self.initProvider) && has(self.initProvider.serviceName))",message="spec.forProvider.serviceName is a required parameter" Spec ProjectDatabaseKafkaTopicSpec `json:"spec"` diff --git a/apis/databases/v1alpha1/zz_projectdatabasem3dbnamespace_types.go b/apis/databases/v1alpha1/zz_projectdatabasem3dbnamespace_types.go index 19e3b2e..83b9556 100755 --- a/apis/databases/v1alpha1/zz_projectdatabasem3dbnamespace_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabasem3dbnamespace_types.go @@ -16,8 +16,17 @@ import ( type ProjectDatabaseM3DbNamespaceInitParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Name of the namespace Name *string `json:"name,omitempty" tf:"name,omitempty"` @@ -91,9 +100,18 @@ type ProjectDatabaseM3DbNamespaceObservation struct { type ProjectDatabaseM3DbNamespaceParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Name of the namespace // +kubebuilder:validation:Optional Name *string `json:"name,omitempty" tf:"name,omitempty"` @@ -170,7 +188,6 @@ type ProjectDatabaseM3DbNamespaceStatus struct { type ProjectDatabaseM3DbNamespace struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.name) || (has(self.initProvider) && has(self.initProvider.name))",message="spec.forProvider.name is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.resolution) || (has(self.initProvider) && has(self.initProvider.resolution))",message="spec.forProvider.resolution is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.retentionPeriodDuration) || (has(self.initProvider) && has(self.initProvider.retentionPeriodDuration))",message="spec.forProvider.retentionPeriodDuration is a required parameter" diff --git a/apis/databases/v1alpha1/zz_projectdatabasem3dbuser_types.go b/apis/databases/v1alpha1/zz_projectdatabasem3dbuser_types.go index ff30775..a0a106c 100755 --- a/apis/databases/v1alpha1/zz_projectdatabasem3dbuser_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabasem3dbuser_types.go @@ -16,8 +16,17 @@ import ( type ProjectDatabaseM3DbUserInitParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Group of the user Group *string `json:"group,omitempty" tf:"group,omitempty"` @@ -58,9 +67,18 @@ type ProjectDatabaseM3DbUserObservation struct { type ProjectDatabaseM3DbUserParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Group of the user // +kubebuilder:validation:Optional Group *string `json:"group,omitempty" tf:"group,omitempty"` @@ -113,7 +131,6 @@ type ProjectDatabaseM3DbUserStatus struct { type ProjectDatabaseM3DbUser struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.name) || (has(self.initProvider) && has(self.initProvider.name))",message="spec.forProvider.name is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serviceName) || (has(self.initProvider) && has(self.initProvider.serviceName))",message="spec.forProvider.serviceName is a required parameter" Spec ProjectDatabaseM3DbUserSpec `json:"spec"` diff --git a/apis/databases/v1alpha1/zz_projectdatabasemongodbuser_types.go b/apis/databases/v1alpha1/zz_projectdatabasemongodbuser_types.go index 9cabd77..151de80 100755 --- a/apis/databases/v1alpha1/zz_projectdatabasemongodbuser_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabasemongodbuser_types.go @@ -16,8 +16,17 @@ import ( type ProjectDatabaseMongodbUserInitParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Name of the user Name *string `json:"name,omitempty" tf:"name,omitempty"` @@ -60,9 +69,18 @@ type ProjectDatabaseMongodbUserObservation struct { type ProjectDatabaseMongodbUserParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Name of the user // +kubebuilder:validation:Optional Name *string `json:"name,omitempty" tf:"name,omitempty"` @@ -116,7 +134,6 @@ type ProjectDatabaseMongodbUserStatus struct { type ProjectDatabaseMongodbUser struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.name) || (has(self.initProvider) && has(self.initProvider.name))",message="spec.forProvider.name is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serviceName) || (has(self.initProvider) && has(self.initProvider.serviceName))",message="spec.forProvider.serviceName is a required parameter" Spec ProjectDatabaseMongodbUserSpec `json:"spec"` diff --git a/apis/databases/v1alpha1/zz_projectdatabaseopensearchpattern_types.go b/apis/databases/v1alpha1/zz_projectdatabaseopensearchpattern_types.go index 7e60f17..90aa830 100755 --- a/apis/databases/v1alpha1/zz_projectdatabaseopensearchpattern_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabaseopensearchpattern_types.go @@ -16,8 +16,17 @@ import ( type ProjectDatabaseOpensearchPatternInitParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Maximum number of index for this pattern MaxIndexCount *float64 `json:"maxIndexCount,omitempty" tf:"max_index_count,omitempty"` @@ -46,9 +55,18 @@ type ProjectDatabaseOpensearchPatternObservation struct { type ProjectDatabaseOpensearchPatternParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Maximum number of index for this pattern // +kubebuilder:validation:Optional MaxIndexCount *float64 `json:"maxIndexCount,omitempty" tf:"max_index_count,omitempty"` @@ -97,7 +115,6 @@ type ProjectDatabaseOpensearchPatternStatus struct { type ProjectDatabaseOpensearchPattern struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.pattern) || (has(self.initProvider) && has(self.initProvider.pattern))",message="spec.forProvider.pattern is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serviceName) || (has(self.initProvider) && has(self.initProvider.serviceName))",message="spec.forProvider.serviceName is a required parameter" Spec ProjectDatabaseOpensearchPatternSpec `json:"spec"` diff --git a/apis/databases/v1alpha1/zz_projectdatabaseopensearchuser_types.go b/apis/databases/v1alpha1/zz_projectdatabaseopensearchuser_types.go index ac3ec12..f2fd612 100755 --- a/apis/databases/v1alpha1/zz_projectdatabaseopensearchuser_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabaseopensearchuser_types.go @@ -48,8 +48,17 @@ type ProjectDatabaseOpensearchUserInitParameters struct { Acls []AclsInitParameters `json:"acls,omitempty" tf:"acls,omitempty"` // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Name of the user Name *string `json:"name,omitempty" tf:"name,omitempty"` @@ -91,9 +100,18 @@ type ProjectDatabaseOpensearchUserParameters struct { Acls []AclsParameters `json:"acls,omitempty" tf:"acls,omitempty"` // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Name of the user // +kubebuilder:validation:Optional Name *string `json:"name,omitempty" tf:"name,omitempty"` @@ -142,7 +160,6 @@ type ProjectDatabaseOpensearchUserStatus struct { type ProjectDatabaseOpensearchUser struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.name) || (has(self.initProvider) && has(self.initProvider.name))",message="spec.forProvider.name is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serviceName) || (has(self.initProvider) && has(self.initProvider.serviceName))",message="spec.forProvider.serviceName is a required parameter" Spec ProjectDatabaseOpensearchUserSpec `json:"spec"` diff --git a/apis/databases/v1alpha1/zz_projectdatabasepostgresqlconnectionpool_types.go b/apis/databases/v1alpha1/zz_projectdatabasepostgresqlconnectionpool_types.go index 9da9045..ab83a27 100755 --- a/apis/databases/v1alpha1/zz_projectdatabasepostgresqlconnectionpool_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabasepostgresqlconnectionpool_types.go @@ -16,8 +16,17 @@ import ( type ProjectDatabasePostgresqlConnectionPoolInitParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Database used for the connection pool DatabaseID *string `json:"databaseId,omitempty" tf:"database_id,omitempty"` @@ -73,9 +82,18 @@ type ProjectDatabasePostgresqlConnectionPoolObservation struct { type ProjectDatabasePostgresqlConnectionPoolParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Database used for the connection pool // +kubebuilder:validation:Optional DatabaseID *string `json:"databaseId,omitempty" tf:"database_id,omitempty"` @@ -136,7 +154,6 @@ type ProjectDatabasePostgresqlConnectionPoolStatus struct { type ProjectDatabasePostgresqlConnectionPool struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.databaseId) || (has(self.initProvider) && has(self.initProvider.databaseId))",message="spec.forProvider.databaseId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.mode) || (has(self.initProvider) && has(self.initProvider.mode))",message="spec.forProvider.mode is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.name) || (has(self.initProvider) && has(self.initProvider.name))",message="spec.forProvider.name is a required parameter" diff --git a/apis/databases/v1alpha1/zz_projectdatabasepostgresqluser_types.go b/apis/databases/v1alpha1/zz_projectdatabasepostgresqluser_types.go index 11deef7..e559958 100755 --- a/apis/databases/v1alpha1/zz_projectdatabasepostgresqluser_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabasepostgresqluser_types.go @@ -16,8 +16,17 @@ import ( type ProjectDatabasePostgresqlUserInitParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Name of the user Name *string `json:"name,omitempty" tf:"name,omitempty"` @@ -60,9 +69,18 @@ type ProjectDatabasePostgresqlUserObservation struct { type ProjectDatabasePostgresqlUserParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Name of the user // +kubebuilder:validation:Optional Name *string `json:"name,omitempty" tf:"name,omitempty"` @@ -116,7 +134,6 @@ type ProjectDatabasePostgresqlUserStatus struct { type ProjectDatabasePostgresqlUser struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.name) || (has(self.initProvider) && has(self.initProvider.name))",message="spec.forProvider.name is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serviceName) || (has(self.initProvider) && has(self.initProvider.serviceName))",message="spec.forProvider.serviceName is a required parameter" Spec ProjectDatabasePostgresqlUserSpec `json:"spec"` diff --git a/apis/databases/v1alpha1/zz_projectdatabaseredisuser_types.go b/apis/databases/v1alpha1/zz_projectdatabaseredisuser_types.go index aef0ceb..107c34c 100755 --- a/apis/databases/v1alpha1/zz_projectdatabaseredisuser_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabaseredisuser_types.go @@ -24,8 +24,17 @@ type ProjectDatabaseRedisUserInitParameters struct { Channels []*string `json:"channels,omitempty" tf:"channels,omitempty"` // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Commands of the user // +listType=set Commands []*string `json:"commands,omitempty" tf:"commands,omitempty"` @@ -94,9 +103,18 @@ type ProjectDatabaseRedisUserParameters struct { Channels []*string `json:"channels,omitempty" tf:"channels,omitempty"` // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Commands of the user // +kubebuilder:validation:Optional // +listType=set @@ -155,7 +173,6 @@ type ProjectDatabaseRedisUserStatus struct { type ProjectDatabaseRedisUser struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.name) || (has(self.initProvider) && has(self.initProvider.name))",message="spec.forProvider.name is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serviceName) || (has(self.initProvider) && has(self.initProvider.serviceName))",message="spec.forProvider.serviceName is a required parameter" Spec ProjectDatabaseRedisUserSpec `json:"spec"` diff --git a/apis/databases/v1alpha1/zz_projectdatabaseuser_types.go b/apis/databases/v1alpha1/zz_projectdatabaseuser_types.go index d36ef91..6971b24 100755 --- a/apis/databases/v1alpha1/zz_projectdatabaseuser_types.go +++ b/apis/databases/v1alpha1/zz_projectdatabaseuser_types.go @@ -16,8 +16,17 @@ import ( type ProjectDatabaseUserInitParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Name of the engine of the service Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` @@ -58,9 +67,18 @@ type ProjectDatabaseUserObservation struct { type ProjectDatabaseUserParameters struct { // Id of the database cluster + // +crossplane:generate:reference:type=github.com/edixos/provider-ovh/apis/databases/v1alpha1.ProjectDatabase // +kubebuilder:validation:Optional ClusterID *string `json:"clusterId,omitempty" tf:"cluster_id,omitempty"` + // Reference to a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDRef *v1.Reference `json:"clusterIdRef,omitempty" tf:"-"` + + // Selector for a ProjectDatabase in databases to populate clusterId. + // +kubebuilder:validation:Optional + ClusterIDSelector *v1.Selector `json:"clusterIdSelector,omitempty" tf:"-"` + // Name of the engine of the service // +kubebuilder:validation:Optional Engine *string `json:"engine,omitempty" tf:"engine,omitempty"` @@ -113,7 +131,6 @@ type ProjectDatabaseUserStatus struct { type ProjectDatabaseUser struct { metav1.TypeMeta `json:",inline"` metav1.ObjectMeta `json:"metadata,omitempty"` - // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.clusterId) || (has(self.initProvider) && has(self.initProvider.clusterId))",message="spec.forProvider.clusterId is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.engine) || (has(self.initProvider) && has(self.initProvider.engine))",message="spec.forProvider.engine is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.name) || (has(self.initProvider) && has(self.initProvider.name))",message="spec.forProvider.name is a required parameter" // +kubebuilder:validation:XValidation:rule="!('*' in self.managementPolicies || 'Create' in self.managementPolicies || 'Update' in self.managementPolicies) || has(self.forProvider.serviceName) || (has(self.initProvider) && has(self.initProvider.serviceName))",message="spec.forProvider.serviceName is a required parameter" diff --git a/apis/gateway/v1alpha1/zz_generated.deepcopy.go b/apis/gateway/v1alpha1/zz_generated.deepcopy.go index 483103a..42590e0 100644 --- a/apis/gateway/v1alpha1/zz_generated.deepcopy.go +++ b/apis/gateway/v1alpha1/zz_generated.deepcopy.go @@ -9,7 +9,7 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( - v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" + "github.com/crossplane/crossplane-runtime/apis/common/v1" runtime "k8s.io/apimachinery/pkg/runtime" ) diff --git a/apis/gateway/v1alpha1/zz_generated.resolvers.go b/apis/gateway/v1alpha1/zz_generated.resolvers.go index 5bb41da..0978471 100644 --- a/apis/gateway/v1alpha1/zz_generated.resolvers.go +++ b/apis/gateway/v1alpha1/zz_generated.resolvers.go @@ -7,7 +7,6 @@ package v1alpha1 import ( "context" - reference "github.com/crossplane/crossplane-runtime/pkg/reference" v1alpha1 "github.com/edixos/provider-ovh/apis/network/v1alpha1" errors "github.com/pkg/errors" diff --git a/apis/kube/v1alpha1/zz_generated.deepcopy.go b/apis/kube/v1alpha1/zz_generated.deepcopy.go index 25ceb2a..3052bcc 100644 --- a/apis/kube/v1alpha1/zz_generated.deepcopy.go +++ b/apis/kube/v1alpha1/zz_generated.deepcopy.go @@ -9,7 +9,7 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( - v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" + "github.com/crossplane/crossplane-runtime/apis/common/v1" runtime "k8s.io/apimachinery/pkg/runtime" ) diff --git a/apis/kube/v1alpha1/zz_generated.resolvers.go b/apis/kube/v1alpha1/zz_generated.resolvers.go index e6aed91..93bde98 100644 --- a/apis/kube/v1alpha1/zz_generated.resolvers.go +++ b/apis/kube/v1alpha1/zz_generated.resolvers.go @@ -7,7 +7,6 @@ package v1alpha1 import ( "context" - reference "github.com/crossplane/crossplane-runtime/pkg/reference" v1alpha1 "github.com/edixos/provider-ovh/apis/network/v1alpha1" errors "github.com/pkg/errors" diff --git a/apis/me/v1alpha1/zz_generated.deepcopy.go b/apis/me/v1alpha1/zz_generated.deepcopy.go index acf30b4..0e15b3c 100644 --- a/apis/me/v1alpha1/zz_generated.deepcopy.go +++ b/apis/me/v1alpha1/zz_generated.deepcopy.go @@ -9,7 +9,7 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( - v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" + "github.com/crossplane/crossplane-runtime/apis/common/v1" runtime "k8s.io/apimachinery/pkg/runtime" ) diff --git a/apis/me/v1alpha1/zz_generated.resolvers.go b/apis/me/v1alpha1/zz_generated.resolvers.go index d10a86d..3958e75 100644 --- a/apis/me/v1alpha1/zz_generated.resolvers.go +++ b/apis/me/v1alpha1/zz_generated.resolvers.go @@ -7,7 +7,6 @@ package v1alpha1 import ( "context" - reference "github.com/crossplane/crossplane-runtime/pkg/reference" errors "github.com/pkg/errors" client "sigs.k8s.io/controller-runtime/pkg/client" diff --git a/apis/network/v1alpha1/zz_generated.deepcopy.go b/apis/network/v1alpha1/zz_generated.deepcopy.go index ad0a6ad..2777ebf 100644 --- a/apis/network/v1alpha1/zz_generated.deepcopy.go +++ b/apis/network/v1alpha1/zz_generated.deepcopy.go @@ -9,7 +9,7 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( - v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" + "github.com/crossplane/crossplane-runtime/apis/common/v1" runtime "k8s.io/apimachinery/pkg/runtime" ) diff --git a/apis/network/v1alpha1/zz_generated.resolvers.go b/apis/network/v1alpha1/zz_generated.resolvers.go index a699769..cdd527e 100644 --- a/apis/network/v1alpha1/zz_generated.resolvers.go +++ b/apis/network/v1alpha1/zz_generated.resolvers.go @@ -7,7 +7,6 @@ package v1alpha1 import ( "context" - reference "github.com/crossplane/crossplane-runtime/pkg/reference" errors "github.com/pkg/errors" client "sigs.k8s.io/controller-runtime/pkg/client" diff --git a/apis/registry/v1alpha1/zz_generated.deepcopy.go b/apis/registry/v1alpha1/zz_generated.deepcopy.go index 575cc8d..7089b7e 100644 --- a/apis/registry/v1alpha1/zz_generated.deepcopy.go +++ b/apis/registry/v1alpha1/zz_generated.deepcopy.go @@ -9,7 +9,7 @@ Copyright 2022 Upbound Inc. package v1alpha1 import ( - v1 "github.com/crossplane/crossplane-runtime/apis/common/v1" + "github.com/crossplane/crossplane-runtime/apis/common/v1" runtime "k8s.io/apimachinery/pkg/runtime" ) diff --git a/apis/registry/v1alpha1/zz_generated.resolvers.go b/apis/registry/v1alpha1/zz_generated.resolvers.go index 2c7e475..e28f75b 100644 --- a/apis/registry/v1alpha1/zz_generated.resolvers.go +++ b/apis/registry/v1alpha1/zz_generated.resolvers.go @@ -7,7 +7,6 @@ package v1alpha1 import ( "context" - reference "github.com/crossplane/crossplane-runtime/pkg/reference" errors "github.com/pkg/errors" client "sigs.k8s.io/controller-runtime/pkg/client" diff --git a/config/databases/config.go b/config/databases/config.go index 45210e3..0aa8624 100644 --- a/config/databases/config.go +++ b/config/databases/config.go @@ -13,47 +13,92 @@ func Configure(p *config.Provider) { }) p.AddResourceConfigurator("ovh_cloud_project_database_database", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) p.AddResourceConfigurator("ovh_cloud_project_database_integration", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) p.AddResourceConfigurator("ovh_cloud_project_database_ip_restriction", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) p.AddResourceConfigurator("ovh_cloud_project_database_kafka_acl", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) p.AddResourceConfigurator("ovh_cloud_project_database_kafka_schemaregistryacl", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) p.AddResourceConfigurator("ovh_cloud_project_database_kafka_topic", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) p.AddResourceConfigurator("ovh_cloud_project_database_m3db_namespace", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) p.AddResourceConfigurator("ovh_cloud_project_database_m3db_user", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) p.AddResourceConfigurator("ovh_cloud_project_database_mongodb_user", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) p.AddResourceConfigurator("ovh_cloud_project_database_opensearch_pattern", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) p.AddResourceConfigurator("ovh_cloud_project_database_opensearch_user", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) p.AddResourceConfigurator("ovh_cloud_project_database_postgresql_user", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) p.AddResourceConfigurator("ovh_cloud_project_database_postgresql_connection_pool", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) p.AddResourceConfigurator("ovh_cloud_project_database_redis_user", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) p.AddResourceConfigurator("ovh_cloud_project_database_user", func(r *config.Resource) { r.ShortGroup = shortGroup + r.References["cluster_id"] = config.Reference{ + TerraformName: "ovh_cloud_project_database", + } }) } diff --git a/config/provider-metadata.yaml b/config/provider-metadata.yaml index 1c7ff54..887044c 100644 --- a/config/provider-metadata.yaml +++ b/config/provider-metadata.yaml @@ -640,24 +640,6 @@ resources: title: domain_zone_dnssec.html Resource - terraform-provider-ovh argumentDocs: {} importStatements: [] - domain_zone_import.html Resource - terraform-provider-ovh: - subCategory: "" - name: domain_zone_import.html Resource - terraform-provider-ovh - title: domain_zone_import.html Resource - terraform-provider-ovh - argumentDocs: {} - importStatements: [] - domain_zone_record.html Resource - terraform-provider-ovh: - subCategory: "" - name: domain_zone_record.html Resource - terraform-provider-ovh - title: domain_zone_record.html Resource - terraform-provider-ovh - argumentDocs: {} - importStatements: [] - domain_zone_redirection.html Resource - terraform-provider-ovh: - subCategory: "" - name: domain_zone_redirection.html Resource - terraform-provider-ovh - title: domain_zone_redirection.html Resource - terraform-provider-ovh - argumentDocs: {} - importStatements: [] hosting_privatedatabase.html Resource - terraform-provider-ovh: subCategory: "" name: hosting_privatedatabase.html Resource - terraform-provider-ovh @@ -994,6 +976,24 @@ resources: title: order_cart_product_plan.html Resource - terraform-provider-ovh argumentDocs: {} importStatements: [] + ovh_domain_zone.html Resource - terraform-provider-ovh: + subCategory: "" + name: ovh_domain_zone.html Resource - terraform-provider-ovh + title: ovh_domain_zone.html Resource - terraform-provider-ovh + argumentDocs: {} + importStatements: [] + ovh_domain_zone_record.html Resource - terraform-provider-ovh: + subCategory: "" + name: ovh_domain_zone_record.html Resource - terraform-provider-ovh + title: ovh_domain_zone_record.html Resource - terraform-provider-ovh + argumentDocs: {} + importStatements: [] + ovh_domain_zone_redirection.html Resource - terraform-provider-ovh: + subCategory: "" + name: ovh_domain_zone_redirection.html Resource - terraform-provider-ovh + title: ovh_domain_zone_redirection.html Resource - terraform-provider-ovh + argumentDocs: {} + importStatements: [] vps.html Resource - terraform-provider-ovh: subCategory: "" name: vps.html Resource - terraform-provider-ovh diff --git a/examples/databases/user-with-cluster-ref.yaml b/examples/databases/user-with-cluster-ref.yaml new file mode 100644 index 0000000..613e3fe --- /dev/null +++ b/examples/databases/user-with-cluster-ref.yaml @@ -0,0 +1,35 @@ +apiVersion: databases.ovh.edixos.io/v1alpha1 +kind: ProjectDatabaseRedisUser +metadata: + name: user-1 + labels: + managed-by: crossplane +spec: + forProvider: + serviceName: 21658141411b4c9bb0bf863be8e8c369 + clusterIdRef: + name: demo-0 + channels: + - "*" + commands: + - +get + - -set + keys: + - data + - properties + name: user-1 + publishConnectionDetailsTo: + name: user-1 + metadata: + labels: + managed-by: crossplane + configRef: + name: staging-01 +--- +apiVersion: ovh.edixos.io/v1alpha1 +kind: StoreConfig +metadata: + name: staging-01 +spec: + defaultScope: default + type: Kubernetes diff --git a/package/crds/databases.ovh.edixos.io_projectdatabasedatabases.yaml b/package/crds/databases.ovh.edixos.io_projectdatabasedatabases.yaml index c4c4945..5b1b598 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabasedatabases.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabasedatabases.yaml @@ -77,6 +77,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object engine: description: Name of the engine of the service type: string @@ -102,6 +178,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object engine: description: Name of the engine of the service type: string @@ -279,10 +431,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.engine is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.engine) diff --git a/package/crds/databases.ovh.edixos.io_projectdatabaseintegrations.yaml b/package/crds/databases.ovh.edixos.io_projectdatabaseintegrations.yaml index 1366659..b1d4538 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabaseintegrations.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabaseintegrations.yaml @@ -77,6 +77,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object destinationServiceId: description: ID of the destination service type: string @@ -114,6 +190,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object destinationServiceId: description: ID of the destination service type: string @@ -303,10 +455,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.destinationServiceId is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.destinationServiceId) diff --git a/package/crds/databases.ovh.edixos.io_projectdatabaseiprestrictions.yaml b/package/crds/databases.ovh.edixos.io_projectdatabaseiprestrictions.yaml index fd22a8c..c0cf231 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabaseiprestrictions.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabaseiprestrictions.yaml @@ -77,6 +77,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object description: description: Description of the IP restriction type: string @@ -105,6 +181,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object description: description: Description of the IP restriction type: string @@ -285,10 +437,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.engine is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.engine) diff --git a/package/crds/databases.ovh.edixos.io_projectdatabasekafkaacls.yaml b/package/crds/databases.ovh.edixos.io_projectdatabasekafkaacls.yaml index 73a9de9..d0ac669 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabasekafkaacls.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabasekafkaacls.yaml @@ -77,6 +77,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object permission: description: Permission to give to this username on this topic type: string @@ -105,6 +181,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object permission: description: Permission to give to this username on this topic type: string @@ -285,10 +437,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.permission is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.permission) diff --git a/package/crds/databases.ovh.edixos.io_projectdatabasekafkaschemaregistryacls.yaml b/package/crds/databases.ovh.edixos.io_projectdatabasekafkaschemaregistryacls.yaml index 58448aa..1f390ec 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabasekafkaschemaregistryacls.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabasekafkaschemaregistryacls.yaml @@ -77,6 +77,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object permission: description: Permission to give to this username on this resource type: string @@ -105,6 +181,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object permission: description: Permission to give to this username on this resource type: string @@ -285,10 +437,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.permission is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.permission) diff --git a/package/crds/databases.ovh.edixos.io_projectdatabasekafkatopics.yaml b/package/crds/databases.ovh.edixos.io_projectdatabasekafkatopics.yaml index bfcdf5b..172e150 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabasekafkatopics.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabasekafkatopics.yaml @@ -77,6 +77,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object minInsyncReplicas: description: Minimum insync replica accepted for this topic type: number @@ -116,6 +192,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object minInsyncReplicas: description: Minimum insync replica accepted for this topic type: number @@ -307,10 +459,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.name is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.name) diff --git a/package/crds/databases.ovh.edixos.io_projectdatabasem3dbnamespaces.yaml b/package/crds/databases.ovh.edixos.io_projectdatabasem3dbnamespaces.yaml index 4b529b0..9e9a29e 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabasem3dbnamespaces.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabasem3dbnamespaces.yaml @@ -77,6 +77,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object name: description: Name of the namespace type: string @@ -129,6 +205,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object name: description: Name of the namespace type: string @@ -333,10 +485,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.name is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.name) diff --git a/package/crds/databases.ovh.edixos.io_projectdatabasem3dbusers.yaml b/package/crds/databases.ovh.edixos.io_projectdatabasem3dbusers.yaml index 8db71cd..d103d9d 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabasem3dbusers.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabasem3dbusers.yaml @@ -77,6 +77,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object group: description: Group of the user type: string @@ -106,6 +182,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object group: description: Group of the user type: string @@ -287,10 +439,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.name is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.name) diff --git a/package/crds/databases.ovh.edixos.io_projectdatabasemongodbusers.yaml b/package/crds/databases.ovh.edixos.io_projectdatabasemongodbusers.yaml index 096a507..081543c 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabasemongodbusers.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabasemongodbusers.yaml @@ -77,6 +77,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object name: description: Name of the user type: string @@ -110,6 +186,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object name: description: Name of the user type: string @@ -295,10 +447,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.name is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.name) diff --git a/package/crds/databases.ovh.edixos.io_projectdatabaseopensearchpatterns.yaml b/package/crds/databases.ovh.edixos.io_projectdatabaseopensearchpatterns.yaml index dc1acfb..6c9f1c3 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabaseopensearchpatterns.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabaseopensearchpatterns.yaml @@ -77,6 +77,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object maxIndexCount: description: Maximum number of index for this pattern type: number @@ -102,6 +178,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object maxIndexCount: description: Maximum number of index for this pattern type: number @@ -279,10 +431,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.pattern is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.pattern) diff --git a/package/crds/databases.ovh.edixos.io_projectdatabaseopensearchusers.yaml b/package/crds/databases.ovh.edixos.io_projectdatabaseopensearchusers.yaml index 017b410..9cb82c9 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabaseopensearchusers.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabaseopensearchusers.yaml @@ -89,6 +89,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object name: description: Name of the user type: string @@ -127,6 +203,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object name: description: Name of the user type: string @@ -305,10 +457,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.name is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.name) diff --git a/package/crds/databases.ovh.edixos.io_projectdatabasepostgresqlconnectionpools.yaml b/package/crds/databases.ovh.edixos.io_projectdatabasepostgresqlconnectionpools.yaml index ceeffef..edcbe76 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabasepostgresqlconnectionpools.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabasepostgresqlconnectionpools.yaml @@ -77,6 +77,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object databaseId: description: Database used for the connection pool type: string @@ -112,6 +188,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object databaseId: description: Database used for the connection pool type: string @@ -299,10 +451,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.databaseId is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.databaseId) diff --git a/package/crds/databases.ovh.edixos.io_projectdatabasepostgresqlusers.yaml b/package/crds/databases.ovh.edixos.io_projectdatabasepostgresqlusers.yaml index 2375ea0..974f8b1 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabasepostgresqlusers.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabasepostgresqlusers.yaml @@ -77,6 +77,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object name: description: Name of the user type: string @@ -109,6 +185,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object name: description: Name of the user type: string @@ -293,10 +445,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.name is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.name) diff --git a/package/crds/databases.ovh.edixos.io_projectdatabaseredisusers.yaml b/package/crds/databases.ovh.edixos.io_projectdatabaseredisusers.yaml index 3707562..73bd4c0 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabaseredisusers.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabaseredisusers.yaml @@ -89,6 +89,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object commands: description: Commands of the user items: @@ -139,6 +215,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object commands: description: Commands of the user items: @@ -329,10 +481,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.name is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.name) diff --git a/package/crds/databases.ovh.edixos.io_projectdatabaseusers.yaml b/package/crds/databases.ovh.edixos.io_projectdatabaseusers.yaml index 6d3601d..fc6965a 100644 --- a/package/crds/databases.ovh.edixos.io_projectdatabaseusers.yaml +++ b/package/crds/databases.ovh.edixos.io_projectdatabaseusers.yaml @@ -76,6 +76,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object engine: description: Name of the engine of the service type: string @@ -105,6 +181,82 @@ spec: clusterId: description: Id of the database cluster type: string + clusterIdRef: + description: Reference to a ProjectDatabase in databases to populate + clusterId. + properties: + name: + description: Name of the referenced object. + type: string + policy: + description: Policies for referencing. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + required: + - name + type: object + clusterIdSelector: + description: Selector for a ProjectDatabase in databases to populate + clusterId. + properties: + matchControllerRef: + description: |- + MatchControllerRef ensures an object with the same controller reference + as the selecting object is selected. + type: boolean + matchLabels: + additionalProperties: + type: string + description: MatchLabels ensures an object with matching labels + is selected. + type: object + policy: + description: Policies for selection. + properties: + resolution: + default: Required + description: |- + Resolution specifies whether resolution of this reference is required. + The default is 'Required', which means the reconcile will fail if the + reference cannot be resolved. 'Optional' means this reference will be + a no-op if it cannot be resolved. + enum: + - Required + - Optional + type: string + resolve: + description: |- + Resolve specifies when this reference should be resolved. The default + is 'IfNotPresent', which will attempt to resolve the reference only when + the corresponding field is not present. Use 'Always' to resolve the + reference on every reconcile. + enum: + - Always + - IfNotPresent + type: string + type: object + type: object engine: description: Name of the engine of the service type: string @@ -286,10 +438,6 @@ spec: - forProvider type: object x-kubernetes-validations: - - message: spec.forProvider.clusterId is a required parameter - rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies - || ''Update'' in self.managementPolicies) || has(self.forProvider.clusterId) - || (has(self.initProvider) && has(self.initProvider.clusterId))' - message: spec.forProvider.engine is a required parameter rule: '!(''*'' in self.managementPolicies || ''Create'' in self.managementPolicies || ''Update'' in self.managementPolicies) || has(self.forProvider.engine)