Skip to content

Commit

Permalink
Merge pull request #2144 from dprotaso/gatewaystatusaddress
Browse files Browse the repository at this point in the history
Gateway::Status::Addresses has a new unique type []GatewayStatusAddress
  • Loading branch information
k8s-ci-robot authored Jul 11, 2023
2 parents 22c7e2a + c0d7567 commit 5e66dc0
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 6 deletions.
20 changes: 19 additions & 1 deletion apis/v1beta1/gateway_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -473,6 +473,24 @@ type GatewayAddress struct {
Value string `json:"value"`
}

// GatewayStatusAddress describes an address that is bound to a Gateway.
type GatewayStatusAddress struct {
// Type of the address.
//
// +optional
// +kubebuilder:default=IPAddress
Type *AddressType `json:"type,omitempty"`

// Value of the address. The validity of the values will depend
// on the type and support by the controller.
//
// Examples: `1.2.3.4`, `128::1`, `my-ip-address`.
//
// +kubebuilder:validation:MinLength=1
// +kubebuilder:validation:MaxLength=253
Value string `json:"value"`
}

// GatewayStatus defines the observed state of Gateway.
type GatewayStatus struct {
// Addresses lists the IP addresses that have actually been
Expand All @@ -482,7 +500,7 @@ type GatewayStatus struct {
//
// +optional
// +kubebuilder:validation:MaxItems=16
Addresses []GatewayAddress `json:"addresses,omitempty"`
Addresses []GatewayStatusAddress `json:"addresses,omitempty"`

// Conditions describe the current conditions of the Gateway.
//
Expand Down
22 changes: 21 additions & 1 deletion apis/v1beta1/zz_generated.deepcopy.go

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

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

4 changes: 2 additions & 2 deletions config/crd/standard/gateway.networking.k8s.io_gateways.yaml

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

0 comments on commit 5e66dc0

Please sign in to comment.