Skip to content

Commit

Permalink
Update api/configuration/v1alpha1/key_set_ref.go
Browse files Browse the repository at this point in the history
Co-authored-by: Patryk Małek <[email protected]>
  • Loading branch information
czeslavo and pmalek committed Sep 20, 2024
1 parent 27377e9 commit d2e9d60
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
4 changes: 2 additions & 2 deletions api/configuration/v1alpha1/key_set_ref.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,15 +23,15 @@ type KeySetRef struct {
// Type defines type of the KeySet object reference. It can be one of:
// - konnectID
// - namespacedRef
Type KeySetRefType `json:"type,omitempty"`
Type KeySetRefType `json:"type"`

// KonnectID is the schema for the KonnectID type.
// This field is required when the Type is konnectID.
// +optional
KonnectID *string `json:"konnectID,omitempty"`

// NamespacedRef is a reference to a KeySet entity inside the cluster.
// This field is required when the Type is konnectNamespacedRef.
// This field is required when the Type is namespacedRef.
// +optional
NamespacedRef *KeySetNamespacedRef `json:"namespacedRef,omitempty"`
}
Expand Down
4 changes: 3 additions & 1 deletion config/crd/bases/configuration.konghq.com_kongkeys.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ spec:
namespacedRef:
description: |-
NamespacedRef is a reference to a KeySet entity inside the cluster.
This field is required when the Type is konnectNamespacedRef.
This field is required when the Type is namespacedRef.
properties:
name:
description: Name is the name of the KeySet object.
Expand All @@ -125,6 +125,8 @@ spec:
- konnectID
- namespacedRef
type: string
required:
- type
type: object
x-kubernetes-validations:
- message: when type is namespacedRef, namespacedRef must be set
Expand Down
2 changes: 1 addition & 1 deletion docs/api-reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -637,7 +637,7 @@ It is used to reference a KeySet entity.
| --- | --- |
| `type` _[KeySetRefType](#keysetreftype)_ | Type defines type of the KeySet object reference. It can be one of: - konnectID - namespacedRef |
| `konnectID` _string_ | KonnectID is the schema for the KonnectID type. This field is required when the Type is konnectID. |
| `namespacedRef` _[KeySetNamespacedRef](#keysetnamespacedref)_ | NamespacedRef is a reference to a KeySet entity inside the cluster. This field is required when the Type is konnectNamespacedRef. |
| `namespacedRef` _[KeySetNamespacedRef](#keysetnamespacedref)_ | NamespacedRef is a reference to a KeySet entity inside the cluster. This field is required when the Type is namespacedRef. |


_Appears in:_
Expand Down

0 comments on commit d2e9d60

Please sign in to comment.