Skip to content

Commit

Permalink
Fix static provisioning
Browse files Browse the repository at this point in the history
crossplane/crossplane-runtime#24

Use the static provisioning compatible predicates introduced in the above PR.

Note the updates to CRDs are due to recent documentation changes in core
fields exposed by crossplane-runtime.

Signed-off-by: Nic Cope <negz@rk0n.org>
  • Loading branch information
negz committed Sep 15, 2019
1 parent 7d3e19c commit 32c5caa
Show file tree
Hide file tree
Showing 22 changed files with 436 additions and 173 deletions.
4 changes: 2 additions & 2 deletions Gopkg.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

41 changes: 28 additions & 13 deletions config/crd/azure.crossplane.io_resourcegroups.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,10 @@ spec:
description: ResourceGroupSpec defines the desired state of Resource Group
properties:
claimRef:
description: ObjectReference contains enough information to let you
inspect or modify the referred object.
description: ClaimReference specifies the resource claim to which this
managed resource will be bound. ClaimReference is set automatically
during dynamic provisioning. Crossplane does not currently support
setting this field manually, per https://github.com/crossplaneio/crossplane-runtime/issues/19
properties:
apiVersion:
description: API version of the referent.
Expand Down Expand Up @@ -70,8 +72,10 @@ spec:
type: string
type: object
classRef:
description: NonPortableClassReference is a reference to a non-portable
class.
description: NonPortableClassReference specifies the non-portable resource
class that was used to dynamically provision this managed resource,
if any. Crossplane does not currently support setting this field manually,
per https://github.com/crossplaneio/crossplane-runtime/issues/20
properties:
apiVersion:
description: API version of the referent.
Expand Down Expand Up @@ -113,8 +117,8 @@ spec:
description: Name of the resource group
type: string
providerRef:
description: ObjectReference contains enough information to let you
inspect or modify the referred object.
description: ProviderReference specifies the provider that will be used
to create, observe, update, and delete this managed resource.
properties:
apiVersion:
description: API version of the referent.
Expand Down Expand Up @@ -150,12 +154,19 @@ spec:
type: string
type: object
reclaimPolicy:
description: A ReclaimPolicy determines what should happen to managed
resources when their bound resource claims are deleted.
description: ReclaimPolicy specifies what will happen to the external
resource this managed resource manages when the managed resource is
deleted. "Delete" deletes the external resource, while "Retain" (the
default) does not. Note this behaviour is subtly different from other
uses of the ReclaimPolicy concept within the Kubernetes ecosystem
per https://github.com/crossplaneio/crossplane-runtime/issues/21
type: string
writeConnectionSecretToRef:
description: LocalObjectReference contains enough information to let
you locate the referenced object inside the same namespace.
description: WriteConnectionSecretToReference specifies the name of
a Secret, in the same namespace as this managed resource, to which
any connection details for this managed resource should be written.
Connection details frequently include the endpoint, username, and
password required to connect to the managed resource.
properties:
name:
description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
Expand All @@ -169,14 +180,18 @@ spec:
description: ResourceGroupStatus is the status for this resource group
properties:
bindingPhase:
description: Phase represents the binding phase of the resource.
description: Phase represents the binding phase of a managed resource
or claim. Unbindable resources cannot be bound, typically because
they are currently unavailable, or still being created. Unbound resource
are available for binding, and Bound resources have successfully bound
to another resource.
enum:
- Unbindable
- Unbound
- Bound
type: string
conditions:
description: Conditions of the managed resource.
description: Conditions of the resource.
items:
description: A Condition that may apply to a managed resource.
properties:
Expand All @@ -199,7 +214,7 @@ spec:
type: string
type:
description: Type of this condition. At most one of each condition
type may apply to a managed resource at any point in time.
type may apply to a resource at any point in time.
type: string
required:
- lastTransitionTime
Expand Down
41 changes: 28 additions & 13 deletions config/crd/cache.azure.crossplane.io_redis.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,10 @@ spec:
directly to an Azure Redis resource. https://docs.microsoft.com/en-us/rest/api/redis/redis/get#redisresource
properties:
claimRef:
description: ObjectReference contains enough information to let you
inspect or modify the referred object.
description: ClaimReference specifies the resource claim to which this
managed resource will be bound. ClaimReference is set automatically
during dynamic provisioning. Crossplane does not currently support
setting this field manually, per https://github.com/crossplaneio/crossplane-runtime/issues/19
properties:
apiVersion:
description: API version of the referent.
Expand Down Expand Up @@ -85,8 +87,10 @@ spec:
type: string
type: object
classRef:
description: NonPortableClassReference is a reference to a non-portable
class.
description: NonPortableClassReference specifies the non-portable resource
class that was used to dynamically provision this managed resource,
if any. Crossplane does not currently support setting this field manually,
per https://github.com/crossplaneio/crossplane-runtime/issues/20
properties:
apiVersion:
description: API version of the referent.
Expand Down Expand Up @@ -129,8 +133,8 @@ spec:
description: Location in which to create this resource.
type: string
providerRef:
description: ObjectReference contains enough information to let you
inspect or modify the referred object.
description: ProviderReference specifies the provider that will be used
to create, observe, update, and delete this managed resource.
properties:
apiVersion:
description: API version of the referent.
Expand Down Expand Up @@ -166,8 +170,12 @@ spec:
type: string
type: object
reclaimPolicy:
description: A ReclaimPolicy determines what should happen to managed
resources when their bound resource claims are deleted.
description: ReclaimPolicy specifies what will happen to the external
resource this managed resource manages when the managed resource is
deleted. "Delete" deletes the external resource, while "Retain" (the
default) does not. Note this behaviour is subtly different from other
uses of the ReclaimPolicy concept within the Kubernetes ecosystem
per https://github.com/crossplaneio/crossplane-runtime/issues/21
type: string
redisConfiguration:
additionalProperties:
Expand Down Expand Up @@ -221,8 +229,11 @@ spec:
a virtual network to deploy the Redis cache in. Example format: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/Microsoft.{Network|ClassicNetwork}/VirtualNetworks/vnet1/subnets/subnet1'
type: string
writeConnectionSecretToRef:
description: LocalObjectReference contains enough information to let
you locate the referenced object inside the same namespace.
description: WriteConnectionSecretToReference specifies the name of
a Secret, in the same namespace as this managed resource, to which
any connection details for this managed resource should be written.
Connection details frequently include the endpoint, username, and
password required to connect to the managed resource.
properties:
name:
description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
Expand All @@ -239,14 +250,18 @@ spec:
description: RedisStatus defines the observed state of Redis
properties:
bindingPhase:
description: Phase represents the binding phase of the resource.
description: Phase represents the binding phase of a managed resource
or claim. Unbindable resources cannot be bound, typically because
they are currently unavailable, or still being created. Unbound resource
are available for binding, and Bound resources have successfully bound
to another resource.
enum:
- Unbindable
- Unbound
- Bound
type: string
conditions:
description: Conditions of the managed resource.
description: Conditions of the resource.
items:
description: A Condition that may apply to a managed resource.
properties:
Expand All @@ -269,7 +284,7 @@ spec:
type: string
type:
description: Type of this condition. At most one of each condition
type may apply to a managed resource at any point in time.
type may apply to a resource at any point in time.
type: string
required:
- lastTransitionTime
Expand Down
13 changes: 9 additions & 4 deletions config/crd/cache.azure.crossplane.io_redisclasses.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,9 @@ spec:
description: Location in which to create this resource.
type: string
providerRef:
description: ObjectReference contains enough information to let you
inspect or modify the referred object.
description: ProviderReference specifies the provider that will be used
to create, observe, update, and delete managed resources that are
dynamically provisioned using this resource class.
properties:
apiVersion:
description: API version of the referent.
Expand Down Expand Up @@ -88,8 +89,12 @@ spec:
type: string
type: object
reclaimPolicy:
description: A ReclaimPolicy determines what should happen to managed
resources when their bound resource claims are deleted.
description: ReclaimPolicy specifies what will happen to external resources
when managed resources dynamically provisioned using this resource
class are deleted. "Delete" deletes the external resource, while "Retain"
(the default) does not. Note this behaviour is subtly different from
other uses of the ReclaimPolicy concept within the Kubernetes ecosystem
per https://github.com/crossplaneio/crossplane-runtime/issues/21
type: string
redisConfiguration:
additionalProperties:
Expand Down
13 changes: 9 additions & 4 deletions config/crd/compute.azure.crossplane.io_aksclusterclasses.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,9 @@ spec:
cluster creation.
type: string
providerRef:
description: ObjectReference contains enough information to let you
inspect or modify the referred object.
description: ProviderReference specifies the provider that will be used
to create, observe, update, and delete managed resources that are
dynamically provisioned using this resource class.
properties:
apiVersion:
description: API version of the referent.
Expand Down Expand Up @@ -107,8 +108,12 @@ spec:
type: string
type: object
reclaimPolicy:
description: A ReclaimPolicy determines what should happen to managed
resources when their bound resource claims are deleted.
description: ReclaimPolicy specifies what will happen to external resources
when managed resources dynamically provisioned using this resource
class are deleted. "Delete" deletes the external resource, while "Retain"
(the default) does not. Note this behaviour is subtly different from
other uses of the ReclaimPolicy concept within the Kubernetes ecosystem
per https://github.com/crossplaneio/crossplane-runtime/issues/21
type: string
resourceGroupName:
description: ResourceGroupName is the name of the resource group that
Expand Down
41 changes: 28 additions & 13 deletions config/crd/compute.azure.crossplane.io_aksclusters.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,10 @@ spec:
description: AKSClusterSpec is the spec for AKS cluster resources
properties:
claimRef:
description: ObjectReference contains enough information to let you
inspect or modify the referred object.
description: ClaimReference specifies the resource claim to which this
managed resource will be bound. ClaimReference is set automatically
during dynamic provisioning. Crossplane does not currently support
setting this field manually, per https://github.com/crossplaneio/crossplane-runtime/issues/19
properties:
apiVersion:
description: API version of the referent.
Expand Down Expand Up @@ -96,8 +98,10 @@ spec:
type: string
type: object
classRef:
description: NonPortableClassReference is a reference to a non-portable
class.
description: NonPortableClassReference specifies the non-portable resource
class that was used to dynamically provision this managed resource,
if any. Crossplane does not currently support setting this field manually,
per https://github.com/crossplaneio/crossplane-runtime/issues/20
properties:
apiVersion:
description: API version of the referent.
Expand Down Expand Up @@ -158,8 +162,8 @@ spec:
cluster creation.
type: string
providerRef:
description: ObjectReference contains enough information to let you
inspect or modify the referred object.
description: ProviderReference specifies the provider that will be used
to create, observe, update, and delete this managed resource.
properties:
apiVersion:
description: API version of the referent.
Expand Down Expand Up @@ -195,8 +199,12 @@ spec:
type: string
type: object
reclaimPolicy:
description: A ReclaimPolicy determines what should happen to managed
resources when their bound resource claims are deleted.
description: ReclaimPolicy specifies what will happen to the external
resource this managed resource manages when the managed resource is
deleted. "Delete" deletes the external resource, while "Retain" (the
default) does not. Note this behaviour is subtly different from other
uses of the ReclaimPolicy concept within the Kubernetes ecosystem
per https://github.com/crossplaneio/crossplane-runtime/issues/21
type: string
resourceGroupName:
description: ResourceGroupName is the name of the resource group that
Expand All @@ -211,8 +219,11 @@ spec:
deployed.
type: string
writeConnectionSecretToRef:
description: LocalObjectReference contains enough information to let
you locate the referenced object inside the same namespace.
description: WriteConnectionSecretToReference specifies the name of
a Secret, in the same namespace as this managed resource, to which
any connection details for this managed resource should be written.
Connection details frequently include the endpoint, username, and
password required to connect to the managed resource.
properties:
name:
description: 'Name of the referent. More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#names
Expand Down Expand Up @@ -246,7 +257,11 @@ spec:
the cluster uses for Azure APIs
type: string
bindingPhase:
description: Phase represents the binding phase of the resource.
description: Phase represents the binding phase of a managed resource
or claim. Unbindable resources cannot be bound, typically because
they are currently unavailable, or still being created. Unbound resource
are available for binding, and Bound resources have successfully bound
to another resource.
enum:
- Unbindable
- Unbound
Expand All @@ -257,7 +272,7 @@ spec:
the cloud provider
type: string
conditions:
description: Conditions of the managed resource.
description: Conditions of the resource.
items:
description: A Condition that may apply to a managed resource.
properties:
Expand All @@ -280,7 +295,7 @@ spec:
type: string
type:
description: Type of this condition. At most one of each condition
type may apply to a managed resource at any point in time.
type may apply to a resource at any point in time.
type: string
required:
- lastTransitionTime
Expand Down
Loading

0 comments on commit 32c5caa

Please sign in to comment.