Skip to content

Commit 53119f5

Browse files
🌱 Bump vm-operator to v1.8.6 (#2914)
* Bump vm-operator to v1.8.6 * Fix CI lint * Fix generated CRD for integration tests * Update vm-operator CRD * Make generate manifests
1 parent 7128032 commit 53119f5

10 files changed

+91
-52
lines changed

‎config/deployments/integration-tests/crds/vmoperator.vmware.com_clustervirtualmachineimages.yaml

+8-2
Original file line numberDiff line numberDiff line change
@@ -220,8 +220,14 @@ spec:
220220
type: object
221221
type: array
222222
contentLibraryRef:
223-
description: ContentLibraryRef is a reference to the source ContentLibrary/ClusterContentLibrary
224-
resource.
223+
description: "ContentLibraryRef is a reference to the source ContentLibrary/ClusterContentLibrary
224+
resource. \n Deprecated: This field is provider specific but the
225+
VirtualMachineImage types are intended to be provider generic. This
226+
field does not exist in later API versions. Instead, the Spec.ProviderRef
227+
field should be used to look up the provider. For images provided
228+
by a Content Library, the ProviderRef will point to either a ContentLibraryItem
229+
or ClusterContentLibraryItem that contains a reference to the Content
230+
Library."
225231
properties:
226232
apiGroup:
227233
description: APIGroup is the group for the resource being referenced.

‎config/deployments/integration-tests/crds/vmoperator.vmware.com_virtualmachineclasses.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ spec:
1414
shortNames:
1515
- vmclass
1616
singular: virtualmachineclass
17-
scope: Cluster
17+
scope: Namespaced
1818
versions:
1919
- additionalPrinterColumns:
2020
- jsonPath: .spec.hardware.cpus

‎config/deployments/integration-tests/crds/vmoperator.vmware.com_virtualmachineimages.yaml

+9-3
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ spec:
1515
- vmi
1616
- vmimage
1717
singular: virtualmachineimage
18-
scope: Cluster
18+
scope: Namespaced
1919
versions:
2020
- additionalPrinterColumns:
2121
- jsonPath: .status.imageName
@@ -220,8 +220,14 @@ spec:
220220
type: object
221221
type: array
222222
contentLibraryRef:
223-
description: ContentLibraryRef is a reference to the source ContentLibrary/ClusterContentLibrary
224-
resource.
223+
description: "ContentLibraryRef is a reference to the source ContentLibrary/ClusterContentLibrary
224+
resource. \n Deprecated: This field is provider specific but the
225+
VirtualMachineImage types are intended to be provider generic. This
226+
field does not exist in later API versions. Instead, the Spec.ProviderRef
227+
field should be used to look up the provider. For images provided
228+
by a Content Library, the ProviderRef will point to either a ContentLibraryItem
229+
or ClusterContentLibraryItem that contains a reference to the Content
230+
Library."
225231
properties:
226232
apiGroup:
227233
description: APIGroup is the group for the resource being referenced.

‎config/deployments/integration-tests/crds/vmoperator.vmware.com_virtualmachines.yaml

+35-19
Original file line numberDiff line numberDiff line change
@@ -98,11 +98,21 @@ spec:
9898
description.
9999
type: string
100100
imageName:
101-
description: ImageName describes the name of a VirtualMachineImage
102-
that is to be used as the base Operating System image of the desired
103-
VirtualMachine instances. The VirtualMachineImage resources can
104-
be introspected to discover identifying attributes that may help
105-
users to identify the desired image to use.
101+
description: "ImageName describes the name of the image resource used
102+
to deploy this VM. \n This field may be used to specify the name
103+
of a VirtualMachineImage or ClusterVirtualMachineImage resource.
104+
The resolver first checks to see if there is a VirtualMachineImage
105+
with the specified name. If no such resource exists, the resolver
106+
then checks to see if there is a ClusterVirtualMachineImage resource
107+
with the specified name in the same Namespace as the VM being deployed.
108+
\n This field may also be used to specify the display name (vSphere
109+
name) of a VirtualMachineImage or ClusterVirtualMachineImage resource.
110+
If the display name unambiguously resolves to a distinct VM image
111+
(among all existing VirtualMachineImages in the VM's namespace and
112+
all existing ClusterVirtualMachineImages), then a mutation webhook
113+
updates this field with the VM image resource name. If the display
114+
name resolves to multiple or no VM images, then the mutation webhook
115+
denies the request and outputs an error message accordingly."
106116
type: string
107117
minHardwareVersion:
108118
description: "MinHardwareVersion specifies the desired minimum hardware
@@ -120,29 +130,30 @@ spec:
120130
field's value is 13, then the VM will be upgraded to hardware version
121131
13. However, if the observed hardware version is 17 and this field's
122132
value is 13, no change will occur. \n Several features are hardware
123-
version dependent, for example: \n * NVMe Controllers \t\t
124-
>= 14 * Dynamic Direct Path I/O devices >= 17 \n Please refer to
125-
https://kb.vmware.com/s/article/1003746 for a list of VM hardware
126-
versions. \n It is important to remember that a VM's hardware version
127-
may not be downgraded and upgrading a VM deployed from an image
128-
based on an older hardware version to a more recent one may result
129-
in unpredictable behavior. In other words, please be careful when
130-
choosing to upgrade a VM to a newer hardware version."
133+
version dependent, for example: \n * NVMe Controllers >=
134+
14 * Dynamic Direct Path I/O devices >= 17 \n Please refer to https://kb.vmware.com/s/article/1003746
135+
for a list of VM hardware versions. \n It is important to remember
136+
that a VM's hardware version may not be downgraded and upgrading
137+
a VM deployed from an image based on an older hardware version to
138+
a more recent one may result in unpredictable behavior. In other
139+
words, please be careful when choosing to upgrade a VM to a newer
140+
hardware version."
131141
format: int32
132142
minimum: 13
133143
type: integer
134144
networkInterfaces:
135-
description: NetworkInterfaces describes a list of VirtualMachineNetworkInterfaces
145+
description: "NetworkInterfaces describes a list of VirtualMachineNetworkInterfaces
136146
to be configured on the VirtualMachine instance. Each of these VirtualMachineNetworkInterfaces
137147
describes external network integration configurations that are to
138148
be used by the VirtualMachine controller when integrating the VirtualMachine
139-
into one or more external networks.
149+
into one or more external networks. \n The maximum number of network
150+
interface allowed is 10 because of the limit built into vSphere."
140151
items:
141152
description: VirtualMachineNetworkInterface defines the properties
142153
of a network interface to attach to a VirtualMachine instance. A
143154
VirtualMachineNetworkInterface describes network interface configuration
144155
that is used by the VirtualMachine controller when integrating
145-
the VirtualMachine into a VirtualNetwork. Currently, only NSX-T
156+
the VirtualMachine into a VirtualNetwork. Currently, only NSX-T
146157
and vSphere Distributed Switch (VDS) type network integrations
147158
are supported using this VirtualMachineNetworkInterface structure.
148159
properties:
@@ -162,8 +173,9 @@ spec:
162173
type: string
163174
networkType:
164175
description: NetworkType describes the type of VirtualNetwork
165-
that is referenced by the NetworkName. Currently, the only
166-
supported NetworkTypes are "nsx-t" and "vsphere-distributed".
176+
that is referenced by the NetworkName. Currently, the supported
177+
NetworkTypes are "nsx-t", "nsx-t-subnet", "nsx-t-subnetset"
178+
and "vsphere-distributed".
167179
type: string
168180
providerRef:
169181
description: ProviderRef is reference to a network interface
@@ -189,6 +201,7 @@ spec:
189201
- name
190202
type: object
191203
type: object
204+
maxItems: 10
192205
type: array
193206
nextRestartTime:
194207
description: "NextRestartTime may be used to restart the VM, in accordance
@@ -278,7 +291,10 @@ spec:
278291
minimum: 1
279292
type: integer
280293
tcpSocket:
281-
description: TCPSocket specifies an action involving a TCP port.
294+
description: "TCPSocket specifies an action involving a TCP port.
295+
\n Deprecated: The TCPSocket action requires network connectivity
296+
that is not supported in all environments. This field will be
297+
removed in a later API version."
282298
properties:
283299
host:
284300
description: Host is an optional host name to connect to. Host

‎config/deployments/integration-tests/crds/vmoperator.vmware.com_virtualmachineservices.yaml

+4-1
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,10 @@ spec:
7979
This feature depends on whether the underlying load balancer provider
8080
supports specifying the loadBalancerIP when a load balancer is created.
8181
This field will be ignored if the provider does not support the
82-
feature.'
82+
feature. Deprecated: This field was under-specified and its meaning
83+
varies across implementations. Using it is non-portable and it may
84+
not support dual-stack. Users are encouraged to use implementation-specific
85+
annotations when available.'
8386
type: string
8487
loadBalancerSourceRanges:
8588
description: 'LoadBalancerSourceRanges is an array of IP addresses

‎go.mod

+6-4
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ go 1.21
44

55
replace sigs.k8s.io/cluster-api => sigs.k8s.io/cluster-api v1.7.0
66

7+
replace github.com/vmware-tanzu/vm-operator/pkg/constants/testlabels => github.com/vmware-tanzu/vm-operator/pkg/constants/testlabels v0.0.0-20240404200847-de75746a9505
8+
79
require (
810
github.com/blang/semver/v4 v4.0.0
911
github.com/go-logr/logr v1.4.1
@@ -14,11 +16,11 @@ require (
1416
github.com/pkg/errors v0.9.1
1517
github.com/spf13/cobra v1.8.0
1618
github.com/stretchr/testify v1.9.0
17-
github.com/vmware-tanzu/net-operator-api v0.0.0-20231019160108-42131d6e8360
19+
github.com/vmware-tanzu/net-operator-api v0.0.0-20240326163340-1f32d6bf7f9d
1820
github.com/vmware-tanzu/nsx-operator/pkg/apis v0.1.0
19-
github.com/vmware-tanzu/vm-operator/api v1.8.5
20-
github.com/vmware-tanzu/vm-operator/external/ncp v0.0.0-20231214185006-5477585eebfd
21-
github.com/vmware-tanzu/vm-operator/external/tanzu-topology v0.0.0-20231214185006-5477585eebfd
21+
github.com/vmware-tanzu/vm-operator/api v1.8.6
22+
github.com/vmware-tanzu/vm-operator/external/ncp v0.0.0-20240404200847-de75746a9505
23+
github.com/vmware-tanzu/vm-operator/external/tanzu-topology v0.0.0-20240404200847-de75746a9505
2224
github.com/vmware/govmomi v0.37.0
2325
golang.org/x/exp v0.0.0-20230905200255-921286631fa9
2426
golang.org/x/mod v0.17.0

‎go.sum

+10-8
Original file line numberDiff line numberDiff line change
@@ -549,16 +549,18 @@ github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1
549549
github.com/tmc/grpc-websocket-proxy v0.0.0-20220101234140-673ab2c3ae75 h1:6fotK7otjonDflCTK0BCfls4SPy3NcCVb5dqqmbRknE=
550550
github.com/tmc/grpc-websocket-proxy v0.0.0-20220101234140-673ab2c3ae75/go.mod h1:KO6IkyS8Y3j8OdNO85qEYBsRPuteD+YciPomcXdrMnk=
551551
github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA=
552-
github.com/vmware-tanzu/net-operator-api v0.0.0-20231019160108-42131d6e8360 h1:yG158jviUd3wRqCTJcSDzp+prUZWtSA9dhfm/Rf8m9M=
553-
github.com/vmware-tanzu/net-operator-api v0.0.0-20231019160108-42131d6e8360/go.mod h1:dtVG693FvGuOSxJvTaKRVGU0EJR8yvLG3E2VaDDHILM=
552+
github.com/vmware-tanzu/net-operator-api v0.0.0-20240326163340-1f32d6bf7f9d h1:cgx9UH/r53bKU/Gbv8IPsUZ34bj5+ItijA2JCUS3kVk=
553+
github.com/vmware-tanzu/net-operator-api v0.0.0-20240326163340-1f32d6bf7f9d/go.mod h1:JbFOh22iDsT5BowJe0GgpMI5e2/S7cWaJlv9LdURVQM=
554554
github.com/vmware-tanzu/nsx-operator/pkg/apis v0.1.0 h1:HdnQb/X9vJ8a5WQ03g/0nDr9igIIK1fF6wO5wOtkJT4=
555555
github.com/vmware-tanzu/nsx-operator/pkg/apis v0.1.0/go.mod h1:Q4JzNkNMvjo7pXtlB5/R3oME4Nhah7fAObWgghVmtxk=
556-
github.com/vmware-tanzu/vm-operator/api v1.8.5 h1:E8rpRdV8+cNp/eNZ/QUHvlrbpPh8uk6bKqwEEmGWe64=
557-
github.com/vmware-tanzu/vm-operator/api v1.8.5/go.mod h1:SXaSFtnw2502Tzy0bfQVHrvbFDijR96r1ihUYQWPOK8=
558-
github.com/vmware-tanzu/vm-operator/external/ncp v0.0.0-20231214185006-5477585eebfd h1:qdfVf7KFW+XX7+D4xC/mlBpRA9+B+opdDPxGdqjxO+4=
559-
github.com/vmware-tanzu/vm-operator/external/ncp v0.0.0-20231214185006-5477585eebfd/go.mod h1:5rqRJ9zGR+KnKbkGx373WgN8xJpvAj99kHnfoDYRO5I=
560-
github.com/vmware-tanzu/vm-operator/external/tanzu-topology v0.0.0-20231214185006-5477585eebfd h1:BleW2NxLCPbLvFoTzhoX/DsjCJuKyEdcmvYiY04k18U=
561-
github.com/vmware-tanzu/vm-operator/external/tanzu-topology v0.0.0-20231214185006-5477585eebfd/go.mod h1:dfYrWS8DMRN+XZfhu8M4LVHmeGvYB29Ipd7j4uIq+mU=
556+
github.com/vmware-tanzu/vm-operator/api v1.8.6 h1:NIndORjcnSmIlQsCMIewpIwg/ocRVDh2lYjOroTVLrU=
557+
github.com/vmware-tanzu/vm-operator/api v1.8.6/go.mod h1:HHA2SNI9B5Yqtyp5t+Gt9WTWBi/fIkM6+MukDDSf11A=
558+
github.com/vmware-tanzu/vm-operator/external/ncp v0.0.0-20240404200847-de75746a9505 h1:y4wXx1FUFqqSgJ/xUOEM1DLS2Uu0KaeLADWpzpioGTU=
559+
github.com/vmware-tanzu/vm-operator/external/ncp v0.0.0-20240404200847-de75746a9505/go.mod h1:5rqRJ9zGR+KnKbkGx373WgN8xJpvAj99kHnfoDYRO5I=
560+
github.com/vmware-tanzu/vm-operator/external/tanzu-topology v0.0.0-20240404200847-de75746a9505 h1:/6vFL20UMHOeTf/mb+dKf5sFG0FBbyrCBY/71QKAIE0=
561+
github.com/vmware-tanzu/vm-operator/external/tanzu-topology v0.0.0-20240404200847-de75746a9505/go.mod h1:dfYrWS8DMRN+XZfhu8M4LVHmeGvYB29Ipd7j4uIq+mU=
562+
github.com/vmware-tanzu/vm-operator/pkg/constants/testlabels v0.0.0-20240404200847-de75746a9505 h1:LRMZ+zzb944d6r+uYsE+CuJ3zVBE6Hc8vjH7IJX2QY4=
563+
github.com/vmware-tanzu/vm-operator/pkg/constants/testlabels v0.0.0-20240404200847-de75746a9505/go.mod h1:M+6bZCS8vSjCN9OOppnAyYxeBxY1U0wG6+j3CvIrOHY=
562564
github.com/vmware/govmomi v0.37.0 h1:xX5AnIrVn4yfH0fYSjyjMg/Kq6q7cNxA+vyfV5YcF70=
563565
github.com/vmware/govmomi v0.37.0/go.mod h1:mtGWtM+YhTADHlCgJBiskSRPOZRsN9MSjPzaZLte/oQ=
564566
github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2 h1:eY9dn8+vbi4tKz5Qo6v2eYzo7kUS51QINcR5jNpbZS8=

‎pkg/services/vmoperator/vmopmachine_test.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ import (
3737
vmwarev1 "sigs.k8s.io/cluster-api-provider-vsphere/apis/vmware/v1beta1"
3838
"sigs.k8s.io/cluster-api-provider-vsphere/pkg/context/fake"
3939
"sigs.k8s.io/cluster-api-provider-vsphere/pkg/context/vmware"
40-
network "sigs.k8s.io/cluster-api-provider-vsphere/pkg/services/network"
40+
"sigs.k8s.io/cluster-api-provider-vsphere/pkg/services/network"
4141
"sigs.k8s.io/cluster-api-provider-vsphere/pkg/util"
4242
)
4343

@@ -393,7 +393,7 @@ var _ = Describe("VirtualMachine tests", func() {
393393
requeue, err = vmService.ReconcileNormal(ctx, supervisorMachineContext)
394394
verifyOutput(supervisorMachineContext)
395395

396-
Expect(vmopVM.Spec.ReadinessProbe.TCPSocket.Port.IntValue()).To(Equal(defaultAPIBindPort))
396+
Expect(vmopVM.Spec.ReadinessProbe.TCPSocket.Port.IntValue()).To(Equal(defaultAPIBindPort)) //nolint:staticcheck
397397
})
398398

399399
Specify("Reconcile invalid Machine", func() {

‎test/go.mod

+6-4
Original file line numberDiff line numberDiff line change
@@ -8,15 +8,17 @@ replace sigs.k8s.io/cluster-api/test => sigs.k8s.io/cluster-api/test v1.7.0
88

99
replace sigs.k8s.io/cluster-api-provider-vsphere => ../
1010

11+
replace github.com/vmware-tanzu/vm-operator/pkg/constants/testlabels => github.com/vmware-tanzu/vm-operator/pkg/constants/testlabels v0.0.0-20240404200847-de75746a9505
12+
1113
require (
1214
github.com/dougm/pretty v0.0.0-20171025230240-2ee9d7453c02
1315
github.com/onsi/ginkgo/v2 v2.17.1
1416
github.com/onsi/gomega v1.32.0
1517
github.com/pkg/errors v0.9.1
1618
github.com/spf13/pflag v1.0.5
17-
github.com/vmware-tanzu/net-operator-api v0.0.0-20231019160108-42131d6e8360
18-
github.com/vmware-tanzu/vm-operator/api v1.8.5
19-
github.com/vmware-tanzu/vm-operator/external/tanzu-topology v0.0.0-20231214185006-5477585eebfd
19+
github.com/vmware-tanzu/net-operator-api v0.0.0-20240326163340-1f32d6bf7f9d
20+
github.com/vmware-tanzu/vm-operator/api v1.8.6
21+
github.com/vmware-tanzu/vm-operator/external/tanzu-topology v0.0.0-20240404200847-de75746a9505
2022
github.com/vmware/govmomi v0.37.0
2123
golang.org/x/crypto v0.22.0
2224
gopkg.in/yaml.v2 v2.4.0
@@ -125,7 +127,7 @@ require (
125127
github.com/stoewer/go-strcase v1.2.0 // indirect
126128
github.com/subosito/gotenv v1.6.0 // indirect
127129
github.com/valyala/fastjson v1.6.4 // indirect
128-
github.com/vmware-tanzu/vm-operator/external/ncp v0.0.0-20231214185006-5477585eebfd // indirect
130+
github.com/vmware-tanzu/vm-operator/external/ncp v0.0.0-20240404200847-de75746a9505 // indirect
129131
go.etcd.io/etcd/api/v3 v3.5.13 // indirect
130132
go.etcd.io/etcd/client/pkg/v3 v3.5.13 // indirect
131133
go.etcd.io/etcd/client/v3 v3.5.13 // indirect

0 commit comments

Comments
 (0)