Skip to content

Commit 141028b

Browse files
committed
Add HomeAZ to NodeInfoStatus
In service of adding HomeAZ awareness to apiserver-vnet-integration, this adds HomeAZ to the NodeInfoStatus portion of the NodeInfo CRD. Similar to other elements of NodeInfoStatus, HomeAZ is an optional property of a node that can be communicated. If present, it strictly follows the AZXX format, where XX are two 0-9 integers.
1 parent 0b8ba8a commit 141028b

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

crd/multitenancy/api/v1alpha1/nodeinfo.go

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,10 @@ type NodeInfoStatus struct {
4747
type DeviceInfo struct {
4848
DeviceType DeviceType `json:"deviceType,omitempty"`
4949
MacAddress string `json:"macAddress"`
50+
51+
// +kubebuilder:validation:optional
52+
// +kubebuilder:validation:Pattern=`^AZ\d{2}$`
53+
HomeAZ string `json:"homeAZ,omitempty"`
5054
}
5155

5256
func init() {

crd/multitenancy/manifests/multitenancy.acn.azure.com_nodeinfo.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,9 @@ spec:
5959
- acn.azure.com/vnet-nic
6060
- acn.azure.com/infiniband-nic
6161
type: string
62+
homeAZ:
63+
pattern: ^AZ\d{2}$
64+
type: string
6265
macAddress:
6366
type: string
6467
required:

0 commit comments

Comments
 (0)