Skip to content

Commit f6cd04c

Browse files
rename APIEndpoint to VPCEndpoint (#471)
Signed-off-by: Prajyot-Parab <[email protected]>
1 parent 1cb0de4 commit f6cd04c

File tree

10 files changed

+83
-83
lines changed

10 files changed

+83
-83
lines changed

api/v1alpha3/ibmvpccluster_types.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ type IBMVPCClusterStatus struct {
6060
// Bastion Instance `json:"bastion,omitempty"`
6161
Ready bool `json:"ready"`
6262
Subnet Subnet `json:"subnet,omitempty"`
63-
APIEndpoint APIEndpoint `json:"apiEndpoint,omitempty"`
63+
VPCEndpoint VPCEndpoint `json:"vpcEndpoint,omitempty"`
6464
}
6565

6666
// VPC holds the VPC information

api/v1alpha3/types.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@ type Subnet struct {
3030
Zone *string `json:"zone"`
3131
}
3232

33-
// APIEndpoint describes a APIEndpoint
34-
type APIEndpoint struct {
33+
// VPCEndpoint describes a VPCEndpoint
34+
type VPCEndpoint struct {
3535
Address *string `json:"address"`
3636
FIPID *string `json:"floatingIPID"`
3737
}

api/v1alpha3/zz_generated.deepcopy.go

Lines changed: 26 additions & 26 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

api/v1alpha4/ibmvpccluster_types.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ type IBMVPCClusterStatus struct {
6060
// Bastion Instance `json:"bastion,omitempty"`
6161
Ready bool `json:"ready"`
6262
Subnet Subnet `json:"subnet,omitempty"`
63-
APIEndpoint APIEndpoint `json:"apiEndpoint,omitempty"`
63+
VPCEndpoint VPCEndpoint `json:"vpcEndpoint,omitempty"`
6464
}
6565

6666
// VPC holds the VPC information

api/v1alpha4/types.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,8 @@ type Subnet struct {
3030
Zone *string `json:"zone"`
3131
}
3232

33-
// APIEndpoint describes a APIEndpoint
34-
type APIEndpoint struct {
33+
// VPCEndpoint describes a VPCEndpoint
34+
type VPCEndpoint struct {
3535
Address *string `json:"address"`
3636
FIPID *string `json:"floatingIPID"`
3737
}

api/v1alpha4/zz_generated.deepcopy.go

Lines changed: 26 additions & 26 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

cloud/scope/cluster.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ func (s *ClusterScope) ensureFIPUnique(fipName string) (*vpcv1.FloatingIP, error
188188

189189
// DeleteFloatingIP deletes a Floating IP associated with floating ip id
190190
func (s *ClusterScope) DeleteFloatingIP() error {
191-
fipID := *s.IBMVPCCluster.Status.APIEndpoint.FIPID
191+
fipID := *s.IBMVPCCluster.Status.VPCEndpoint.FIPID
192192
if fipID != "" {
193193
deleteFIPOption := &vpcv1.DeleteFloatingIPOptions{}
194194
deleteFIPOption.SetID(fipID)

config/crd/bases/infrastructure.cluster.x-k8s.io_ibmvpcclusters.yaml

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -82,17 +82,6 @@ spec:
8282
status:
8383
description: IBMVPCClusterStatus defines the observed state of IBMVPCCluster
8484
properties:
85-
apiEndpoint:
86-
description: APIEndpoint describes a APIEndpoint
87-
properties:
88-
address:
89-
type: string
90-
floatingIPID:
91-
type: string
92-
required:
93-
- address
94-
- floatingIPID
95-
type: object
9685
ready:
9786
description: Bastion Instance `json:"bastion,omitempty"`
9887
type: boolean
@@ -126,6 +115,17 @@ spec:
126115
- id
127116
- name
128117
type: object
118+
vpcEndpoint:
119+
description: VPCEndpoint describes a VPCEndpoint
120+
properties:
121+
address:
122+
type: string
123+
floatingIPID:
124+
type: string
125+
required:
126+
- address
127+
- floatingIPID
128+
type: object
129129
required:
130130
- ready
131131
type: object
@@ -198,17 +198,6 @@ spec:
198198
status:
199199
description: IBMVPCClusterStatus defines the observed state of IBMVPCCluster
200200
properties:
201-
apiEndpoint:
202-
description: APIEndpoint describes a APIEndpoint
203-
properties:
204-
address:
205-
type: string
206-
floatingIPID:
207-
type: string
208-
required:
209-
- address
210-
- floatingIPID
211-
type: object
212201
ready:
213202
description: Bastion Instance `json:"bastion,omitempty"`
214203
type: boolean
@@ -242,6 +231,17 @@ spec:
242231
- id
243232
- name
244233
type: object
234+
vpcEndpoint:
235+
description: VPCEndpoint describes a VPCEndpoint
236+
properties:
237+
address:
238+
type: string
239+
floatingIPID:
240+
type: string
241+
required:
242+
- address
243+
- floatingIPID
244+
type: object
245245
required:
246246
- ready
247247
type: object

controllers/ibmvpccluster_controller.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ func (r *IBMVPCClusterReconciler) reconcile(ctx context.Context, clusterScope *s
140140
Port: 6443,
141141
}
142142

143-
clusterScope.IBMVPCCluster.Status.APIEndpoint = infrastructurev1alpha4.APIEndpoint{
143+
clusterScope.IBMVPCCluster.Status.VPCEndpoint = infrastructurev1alpha4.VPCEndpoint{
144144
Address: fip.Address,
145145
FIPID: fip.ID,
146146
}

controllers/ibmvpcmachine_controller.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ func (r *IBMVPCMachineReconciler) reconcileNormal(ctx context.Context, machineSc
173173
machineScope.IBMVPCMachine.Spec.ProviderID = pointer.StringPtr(fmt.Sprintf("ibmvpc://%s/%s", machineScope.Machine.Spec.ClusterName, machineScope.IBMVPCMachine.Name))
174174
if ok {
175175
options := &vpcv1.AddInstanceNetworkInterfaceFloatingIPOptions{}
176-
options.SetID(*machineScope.IBMVPCCluster.Status.APIEndpoint.FIPID)
176+
options.SetID(*machineScope.IBMVPCCluster.Status.VPCEndpoint.FIPID)
177177
options.SetInstanceID(*instance.ID)
178178
options.SetNetworkInterfaceID(*instance.PrimaryNetworkInterface.ID)
179179
floatingIP, _, err :=

0 commit comments

Comments
 (0)