fog-kubevirt 1.7.0 → 1.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/fog/kubevirt/compute/models/vm_base.rb +3 -1
- data/lib/fog/kubevirt/compute/models/vms.rb +38 -22
- data/lib/fog/kubevirt/version.rb +1 -1
- data/spec/fixtures/kubevirt/vm/vm_create_efi.yml +403 -0
- data/spec/unit/create_vm_spec.rb +22 -0
- data/spec/unit/get_server_spec.rb +1 -0
- metadata +5 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 88936198ddc16f905d97de9baf7695edb0ba214bff8da4db1be3c94c2d2ee6e7
|
|
4
|
+
data.tar.gz: fc7de7dcc2beb9ecf9546ceeefb3595970d8090e555ea89712fc02acc15870c1
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: ffe5cf059ddb22edfee3c54b6b58333031cf631650c047df788dcb3842bdc5facd4b7bf58ed9887d13d78abc82150098a4ec496a0f79acb4b1a0892966092c6a
|
|
7
|
+
data.tar.gz: 7fc706efa09875717d37cdc23d105e928787e5f222efd64b5cf0b382ea61034d2f49024df1f1e3183ccfbcc74506de3bd7c7ad33c5f6ef178669903f8e3aca30
|
|
@@ -24,6 +24,7 @@ module Fog
|
|
|
24
24
|
attribute :interfaces, :aliases => 'spec_interfaces'
|
|
25
25
|
attribute :networks, :aliases => 'spec_networks'
|
|
26
26
|
attribute :machine_type, :aliases => 'spec_machine_type'
|
|
27
|
+
attribute :bootloader, :aliases => 'spec_bootloader'
|
|
27
28
|
end
|
|
28
29
|
|
|
29
30
|
def parse_object(object)
|
|
@@ -48,7 +49,8 @@ module Fog
|
|
|
48
49
|
:status => parse_status(object, :printableStatus),
|
|
49
50
|
:interfaces => parse_interfaces(domain[:devices][:interfaces], object[:status].nil? ? [] : object[:status][:interfaces], networks),
|
|
50
51
|
:networks => networks,
|
|
51
|
-
:machine_type => domain.dig(:machine, :type)
|
|
52
|
+
:machine_type => domain.dig(:machine, :type),
|
|
53
|
+
:bootloader => domain.dig(:firmware, :bootloader)
|
|
52
54
|
}
|
|
53
55
|
vm[:owner_reference] = owner unless owner.nil?
|
|
54
56
|
vm[:annotations] = annotations unless annotations.nil?
|
|
@@ -44,36 +44,41 @@ module Fog
|
|
|
44
44
|
service.delete_vm(name, service.namespace)
|
|
45
45
|
end
|
|
46
46
|
|
|
47
|
-
# Creates a virtual machine using provided paramters
|
|
48
|
-
#
|
|
49
|
-
#
|
|
50
|
-
#
|
|
51
|
-
#
|
|
52
|
-
#
|
|
53
|
-
#
|
|
54
|
-
#
|
|
55
|
-
#
|
|
47
|
+
# Creates a virtual machine using provided paramters
|
|
48
|
+
#
|
|
49
|
+
# @param args [Hash] attributes containing details about vm about to be
|
|
50
|
+
# created.
|
|
51
|
+
# @option args [String] :vm_name name of the vm
|
|
52
|
+
# @option args [String,Number,nil] :cpus (nil) number of cpus
|
|
53
|
+
# @option args [String,Number] :memory_size amount of memory
|
|
54
|
+
# @option args ["K","M","G","T"] :memory_unit ("M") memory unit to use
|
|
55
|
+
# @option args [String] :pvc name of a persistent volume claim
|
|
56
|
+
# @option args [Hash] :cloudinit ({}) items for configuring cloud-init
|
|
57
|
+
# @option args [Array<Hash>,nil] :networks (nil) networks to which the vm should be connected, i.e:
|
|
56
58
|
# [ { :name => 'default', :pod => {} } ,
|
|
57
59
|
# { :name => 'ovs-red', :multus => { :networkName => 'red'} }
|
|
58
60
|
# ]
|
|
59
|
-
#
|
|
60
|
-
#
|
|
61
|
-
# :networks section by network's name, i.e.:
|
|
61
|
+
# @option args [Array<Hash>,nil] :interfaces (nil) network interfaces for the vm, correlated to
|
|
62
|
+
# :networks section by network's name, i.e:
|
|
62
63
|
# [ { :name => 'default', :bridge => {} },
|
|
63
64
|
# { :name => 'red', # correlated to networks[networkName]
|
|
64
65
|
# :bridge => {},
|
|
65
66
|
# :bootOrder => 1, # 1 to boot from network interface
|
|
66
67
|
# :macAddress => '12:34:56:AB:CD:EF' }
|
|
67
68
|
# ]
|
|
68
|
-
#
|
|
69
|
-
#
|
|
70
|
-
#
|
|
71
|
-
#
|
|
72
|
-
#
|
|
73
|
-
#
|
|
74
|
-
#
|
|
75
|
-
#
|
|
76
|
-
#
|
|
69
|
+
# @option args [Hash,nil] :extra_domain (nil) extra parameters to merge into the domain-part of the VM object, i.e:
|
|
70
|
+
# {
|
|
71
|
+
# :features => {
|
|
72
|
+
# :smm => { :enabled => true }
|
|
73
|
+
# },
|
|
74
|
+
# :firmware => {
|
|
75
|
+
# :bootloader => {
|
|
76
|
+
# :efi => { :secureBoot => false }
|
|
77
|
+
# }
|
|
78
|
+
# }
|
|
79
|
+
# }
|
|
80
|
+
# @option args [Array<Fog::Kubevirt::Compute::Volume>] :volumes the volumes (Fog::Kubevirt::Compute::Volume) to be used by the VM
|
|
81
|
+
# @option args [Array<Hash>,nil] :volume_templates (nil) the dataVolumeTemplates to be used by the VM
|
|
77
82
|
def create(args = {})
|
|
78
83
|
vm_name = args.fetch(:vm_name)
|
|
79
84
|
cpus = args.fetch(:cpus, nil)
|
|
@@ -82,7 +87,8 @@ module Fog
|
|
|
82
87
|
init = args.fetch(:cloudinit, {})
|
|
83
88
|
networks = args.fetch(:networks, nil)
|
|
84
89
|
interfaces = args.fetch(:interfaces, nil)
|
|
85
|
-
|
|
90
|
+
extra_domain = args.fetch(:extra_domain, nil)
|
|
91
|
+
vm_volumes = args.fetch(:volumes, nil)
|
|
86
92
|
volume_templates = args.fetch(:volume_templates, nil)
|
|
87
93
|
|
|
88
94
|
if vm_volumes.nil? || vm_volumes.empty?
|
|
@@ -187,6 +193,16 @@ module Fog
|
|
|
187
193
|
}
|
|
188
194
|
) unless volume_templates.nil? || volume_templates.empty?
|
|
189
195
|
|
|
196
|
+
vm = deep_merge!(vm,
|
|
197
|
+
:spec => {
|
|
198
|
+
:template => {
|
|
199
|
+
:spec => {
|
|
200
|
+
:domain => extra_domain
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
}
|
|
204
|
+
) unless extra_domain.nil? || extra_domain.empty?
|
|
205
|
+
|
|
190
206
|
service.create_vm(vm)
|
|
191
207
|
end
|
|
192
208
|
|
data/lib/fog/kubevirt/version.rb
CHANGED
|
@@ -0,0 +1,403 @@
|
|
|
1
|
+
---
|
|
2
|
+
http_interactions:
|
|
3
|
+
- request:
|
|
4
|
+
method: get
|
|
5
|
+
uri: https://10.8.254.82:8443/api/v1/namespaces/default/persistentvolumeclaims/mypvc
|
|
6
|
+
body:
|
|
7
|
+
encoding: US-ASCII
|
|
8
|
+
string: ''
|
|
9
|
+
headers:
|
|
10
|
+
Accept:
|
|
11
|
+
- "*/*"
|
|
12
|
+
User-Agent:
|
|
13
|
+
- rest-client/2.1.0 (linux x86_64) ruby/3.3.11p205
|
|
14
|
+
Authorization:
|
|
15
|
+
- Bearer <TOKEN>
|
|
16
|
+
Accept-Encoding:
|
|
17
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
|
18
|
+
response:
|
|
19
|
+
status:
|
|
20
|
+
code: 200
|
|
21
|
+
message: OK
|
|
22
|
+
headers:
|
|
23
|
+
Cache-Control:
|
|
24
|
+
- no-cache, private
|
|
25
|
+
Content-Type:
|
|
26
|
+
- application/json
|
|
27
|
+
Date:
|
|
28
|
+
- Wed, 08 Jul 2026 11:32:17 GMT
|
|
29
|
+
Content-Length:
|
|
30
|
+
- '1715'
|
|
31
|
+
body:
|
|
32
|
+
encoding: UTF-8
|
|
33
|
+
string: '{"kind":"PersistentVolumeClaim","apiVersion":"v1","metadata":{"name":"mypvc","namespace":"default","uid":"606aa700-8b98-41ba-bb89-2beb0dcd22fd","resourceVersion":"4960013197","creationTimestamp":"2026-07-08T11:31:48Z","annotations":{"pv.kubernetes.io/bind-completed":"yes","pv.kubernetes.io/bound-by-controller":"yes","volume.beta.kubernetes.io/storage-provisioner":"local-storage","volume.kubernetes.io/storage-provisioner":"local-storage"},"finalizers":["kubernetes.io/pvc-protection"],"managedFields":[{"manager":"kube-controller-manager","operation":"Update","apiVersion":"v1","time":"2026-07-08T11:31:48Z","fieldsType":"FieldsV1","fieldsV1":{"f:metadata":{"f:annotations":{".":{},"f:pv.kubernetes.io/bind-completed":{},"f:pv.kubernetes.io/bound-by-controller":{},"f:volume.beta.kubernetes.io/storage-provisioner":{},"f:volume.kubernetes.io/storage-provisioner":{}}},"f:spec":{"f:volumeName":{}}}},{"manager":"kube-controller-manager","operation":"Update","apiVersion":"v1","time":"2026-07-08T11:31:48Z","fieldsType":"FieldsV1","fieldsV1":{"f:status":{"f:accessModes":{},"f:capacity":{".":{},"f:storage":{}},"f:phase":{}}},"subresource":"status"},{"manager":"kubectl-create","operation":"Update","apiVersion":"v1","time":"2026-07-08T11:31:48Z","fieldsType":"FieldsV1","fieldsV1":{"f:spec":{"f:accessModes":{},"f:resources":{"f:requests":{".":{},"f:storage":{}}},"f:volumeMode":{}}}}]},"spec":{"accessModes":["ReadWriteOnce"],"resources":{"requests":{"storage":"5Gi"}},"volumeName":"pvc-606aa700-8b98-41ba-bb89-2beb0dcd22fd","storageClassName":"local-storage","volumeMode":"Filesystem"},"status":{"phase":"Bound","accessModes":["ReadWriteOnce"],"capacity":{"storage":"5Gi"}}}
|
|
34
|
+
|
|
35
|
+
'
|
|
36
|
+
recorded_at: Wed, 08 Jul 2026 11:32:17 GMT
|
|
37
|
+
- request:
|
|
38
|
+
method: get
|
|
39
|
+
uri: https://10.8.254.82:8443/apis/kubevirt.io
|
|
40
|
+
body:
|
|
41
|
+
encoding: US-ASCII
|
|
42
|
+
string: ''
|
|
43
|
+
headers:
|
|
44
|
+
Accept:
|
|
45
|
+
- "*/*"
|
|
46
|
+
User-Agent:
|
|
47
|
+
- rest-client/2.1.0 (linux x86_64) ruby/3.3.11p205
|
|
48
|
+
Authorization:
|
|
49
|
+
- Bearer <TOKEN>
|
|
50
|
+
Accept-Encoding:
|
|
51
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
|
52
|
+
response:
|
|
53
|
+
status:
|
|
54
|
+
code: 200
|
|
55
|
+
message: OK
|
|
56
|
+
headers:
|
|
57
|
+
Cache-Control:
|
|
58
|
+
- no-cache, private
|
|
59
|
+
Content-Type:
|
|
60
|
+
- application/json
|
|
61
|
+
Date:
|
|
62
|
+
- Wed, 08 Jul 2026 12:02:02 GMT
|
|
63
|
+
Content-Length:
|
|
64
|
+
- '250'
|
|
65
|
+
body:
|
|
66
|
+
encoding: UTF-8
|
|
67
|
+
string: '{"kind":"APIGroup","apiVersion":"v1","name":"kubevirt.io","versions":[{"groupVersion":"kubevirt.io/v1","version":"v1"},{"groupVersion":"kubevirt.io/v1alpha3","version":"v1alpha3"}],"preferredVersion":{"groupVersion":"kubevirt.io/v1","version":"v1"}}
|
|
68
|
+
|
|
69
|
+
'
|
|
70
|
+
recorded_at: Wed, 08 Jul 2026 12:02:02 GMT
|
|
71
|
+
- request:
|
|
72
|
+
method: get
|
|
73
|
+
uri: https://10.8.254.82:8443/apis/kubevirt.io
|
|
74
|
+
body:
|
|
75
|
+
encoding: US-ASCII
|
|
76
|
+
string: ''
|
|
77
|
+
headers:
|
|
78
|
+
Accept:
|
|
79
|
+
- "*/*"
|
|
80
|
+
User-Agent:
|
|
81
|
+
- rest-client/2.1.0 (linux x86_64) ruby/3.3.11p205
|
|
82
|
+
Authorization:
|
|
83
|
+
- Bearer <TOKEN>
|
|
84
|
+
Accept-Encoding:
|
|
85
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
|
86
|
+
response:
|
|
87
|
+
status:
|
|
88
|
+
code: 200
|
|
89
|
+
message: OK
|
|
90
|
+
headers:
|
|
91
|
+
Content-Type:
|
|
92
|
+
- application/json
|
|
93
|
+
Date:
|
|
94
|
+
- Wed, 08 Jul 2026 12:02:02 GMT
|
|
95
|
+
Content-Length:
|
|
96
|
+
- '250'
|
|
97
|
+
body:
|
|
98
|
+
encoding: UTF-8
|
|
99
|
+
string: '{"kind":"APIGroup","apiVersion":"v1","name":"kubevirt.io","versions":[{"groupVersion":"kubevirt.io/v1","version":"v1"},{"groupVersion":"kubevirt.io/v1alpha3","version":"v1alpha3"}],"preferredVersion":{"groupVersion":"kubevirt.io/v1","version":"v1"}}
|
|
100
|
+
|
|
101
|
+
'
|
|
102
|
+
recorded_at: Wed, 08 Jul 2026 12:02:02 GMT
|
|
103
|
+
- request:
|
|
104
|
+
method: get
|
|
105
|
+
uri: https://10.8.254.82:8443/apis/kubevirt.io/v1
|
|
106
|
+
body:
|
|
107
|
+
encoding: US-ASCII
|
|
108
|
+
string: ''
|
|
109
|
+
headers:
|
|
110
|
+
Accept:
|
|
111
|
+
- "*/*"
|
|
112
|
+
User-Agent:
|
|
113
|
+
- rest-client/2.1.0 (linux x86_64) ruby/3.3.11p205
|
|
114
|
+
Authorization:
|
|
115
|
+
- Bearer <TOKEN>
|
|
116
|
+
Accept-Encoding:
|
|
117
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
|
118
|
+
response:
|
|
119
|
+
status:
|
|
120
|
+
code: 200
|
|
121
|
+
message: OK
|
|
122
|
+
headers:
|
|
123
|
+
Content-Type:
|
|
124
|
+
- application/json
|
|
125
|
+
Date:
|
|
126
|
+
- Wed, 08 Jul 2026 12:02:02 GMT
|
|
127
|
+
Transfer-Encoding:
|
|
128
|
+
- chunked
|
|
129
|
+
body:
|
|
130
|
+
encoding: UTF-8
|
|
131
|
+
string: '{"kind":"APIResourceList","apiVersion":"v1","groupVersion":"kubevirt.io/v1","resources":[{"name":"virtualmachineinstancereplicasets","singularName":"virtualmachineinstancereplicaset","namespaced":true,"kind":"VirtualMachineInstanceReplicaSet","verbs":["delete","deletecollection","get","list","patch","create","update","watch"],"shortNames":["vmirs","vmirss"],"categories":["all"],"storageVersionHash":"VyiLSe/5A2Q="},{"name":"virtualmachineinstancereplicasets/status","singularName":"","namespaced":true,"kind":"VirtualMachineInstanceReplicaSet","verbs":["get","patch","update"]},{"name":"virtualmachineinstancereplicasets/scale","singularName":"","namespaced":true,"group":"autoscaling","version":"v1","kind":"Scale","verbs":["get","patch","update"]},{"name":"virtualmachineinstances","singularName":"virtualmachineinstance","namespaced":true,"kind":"VirtualMachineInstance","verbs":["delete","deletecollection","get","list","patch","create","update","watch"],"shortNames":["vmi","vmis"],"categories":["all"],"storageVersionHash":"1DClFQM6+os="},{"name":"kubevirts","singularName":"kubevirt","namespaced":true,"kind":"KubeVirt","verbs":["delete","deletecollection","get","list","patch","create","update","watch"],"shortNames":["kv","kvs"],"categories":["all"],"storageVersionHash":"+s0w/mxiw14="},{"name":"kubevirts/status","singularName":"","namespaced":true,"kind":"KubeVirt","verbs":["get","patch","update"]},{"name":"virtualmachineinstancemigrations","singularName":"virtualmachineinstancemigration","namespaced":true,"kind":"VirtualMachineInstanceMigration","verbs":["delete","deletecollection","get","list","patch","create","update","watch"],"shortNames":["vmim","vmims"],"categories":["all"],"storageVersionHash":"ByphcRAtdtg="},{"name":"virtualmachineinstancemigrations/status","singularName":"","namespaced":true,"kind":"VirtualMachineInstanceMigration","verbs":["get","patch","update"]},{"name":"virtualmachines","singularName":"virtualmachine","namespaced":true,"kind":"VirtualMachine","verbs":["delete","deletecollection","get","list","patch","create","update","watch"],"shortNames":["vm","vms"],"categories":["all"],"storageVersionHash":"v2rohjOGqcY="},{"name":"virtualmachines/status","singularName":"","namespaced":true,"kind":"VirtualMachine","verbs":["get","patch","update"]},{"name":"virtualmachineinstancepresets","singularName":"virtualmachineinstancepreset","namespaced":true,"kind":"VirtualMachineInstancePreset","verbs":["delete","deletecollection","get","list","patch","create","update","watch"],"shortNames":["vmipreset","vmipresets"],"categories":["all"],"storageVersionHash":"oZZyVoiG8GU="}]}
|
|
132
|
+
|
|
133
|
+
'
|
|
134
|
+
recorded_at: Wed, 08 Jul 2026 12:02:02 GMT
|
|
135
|
+
- request:
|
|
136
|
+
method: post
|
|
137
|
+
uri: https://10.8.254.82:8443/apis/kubevirt.io/v1/namespaces/default/virtualmachines
|
|
138
|
+
body:
|
|
139
|
+
encoding: UTF-8
|
|
140
|
+
string: '{"kind":"VirtualMachine","metadata":{"labels":{"kubevirt.io/vm":"test2"},"name":"test2","namespace":"default"},"spec":{"running":false,"template":{"metadata":{"creationTimestamp":null,"labels":{"kubevirt.io/vm":"test2"}},"spec":{"domain":{"devices":{"disks":[{"name":"test2-disk-00","disk":{"bus":"virtio"}}]},"machine":{"type":""},"resources":{"requests":{"memory":"64M"}},"cpu":{"cores":1},"firmware":{"bootloader":{"efi":{"secureBoot":false}}}},"terminationGracePeriodSeconds":0,"volumes":[{"name":"test2-disk-00","persistentVolumeClaim":{"claimName":"mypvc3"}}]}}},"apiVersion":"kubevirt.io/v1"}'
|
|
141
|
+
headers:
|
|
142
|
+
Accept:
|
|
143
|
+
- "*/*"
|
|
144
|
+
User-Agent:
|
|
145
|
+
- rest-client/2.1.0 (linux x86_64) ruby/3.3.11p205
|
|
146
|
+
Content-Type:
|
|
147
|
+
- application/json
|
|
148
|
+
Authorization:
|
|
149
|
+
- Bearer <TOKEN>
|
|
150
|
+
Content-Length:
|
|
151
|
+
- '609'
|
|
152
|
+
Accept-Encoding:
|
|
153
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
|
154
|
+
response:
|
|
155
|
+
status:
|
|
156
|
+
code: 201
|
|
157
|
+
message: Created
|
|
158
|
+
headers:
|
|
159
|
+
Content-Type:
|
|
160
|
+
- application/json
|
|
161
|
+
Date:
|
|
162
|
+
- Wed, 08 Jul 2026 12:02:02 GMT
|
|
163
|
+
Content-Length:
|
|
164
|
+
- '1585'
|
|
165
|
+
body:
|
|
166
|
+
encoding: UTF-8
|
|
167
|
+
string: '{"apiVersion":"kubevirt.io/v1","kind":"VirtualMachine","metadata":{"creationTimestamp":"2026-07-08T12:02:02Z","generation":1,"labels":{"kubevirt.io/vm":"test2"},"managedFields":[{"apiVersion":"kubevirt.io/v1","fieldsType":"FieldsV1","fieldsV1":{"f:metadata":{"f:labels":{".":{},"f:kubevirt.io/vm":{}}},"f:spec":{".":{},"f:running":{},"f:template":{".":{},"f:metadata":{".":{},"f:creationTimestamp":{},"f:labels":{".":{},"f:kubevirt.io/vm":{}}},"f:spec":{".":{},"f:domain":{".":{},"f:cpu":{".":{},"f:cores":{}},"f:devices":{".":{},"f:disks":{}},"f:firmware":{".":{},"f:bootloader":{".":{},"f:efi":{".":{},"f:secureBoot":{}}}},"f:machine":{".":{},"f:type":{}},"f:resources":{".":{},"f:requests":{".":{},"f:memory":{}}}},"f:terminationGracePeriodSeconds":{},"f:volumes":{}}}}},"manager":"rest-client","operation":"Update","time":"2026-07-08T12:02:02Z"}],"name":"test2","namespace":"default","resourceVersion":"4960050324","uid":"2ee29c23-80b5-420c-b718-ea28414ddc4c"},"spec":{"running":false,"template":{"metadata":{"annotations":{"kubevirt.io/pci-topology-version":"v3"},"labels":{"kubevirt.io/vm":"test2"}},"spec":{"architecture":"amd64","domain":{"cpu":{"cores":1},"devices":{"disks":[{"disk":{"bus":"virtio"},"name":"test2-disk-00"}]},"firmware":{"bootloader":{"efi":{"secureBoot":false}},"serial":"8c595911-21bf-4712-a443-a10914cf9dea","uuid":"5bcd429a-9f7f-4c5a-87fd-51ac744334bf"},"machine":{"type":"q35"},"resources":{"requests":{"memory":"64M"}}},"terminationGracePeriodSeconds":0,"volumes":[{"name":"test2-disk-00","persistentVolumeClaim":{"claimName":"mypvc3"}}]}}}}
|
|
168
|
+
|
|
169
|
+
'
|
|
170
|
+
recorded_at: Wed, 08 Jul 2026 12:02:02 GMT
|
|
171
|
+
- request:
|
|
172
|
+
method: get
|
|
173
|
+
uri: https://10.8.254.82:8443/apis/kubevirt.io
|
|
174
|
+
body:
|
|
175
|
+
encoding: US-ASCII
|
|
176
|
+
string: ''
|
|
177
|
+
headers:
|
|
178
|
+
Accept:
|
|
179
|
+
- "*/*"
|
|
180
|
+
User-Agent:
|
|
181
|
+
- rest-client/2.1.0 (linux x86_64) ruby/3.3.11p205
|
|
182
|
+
Authorization:
|
|
183
|
+
- Bearer <TOKEN>
|
|
184
|
+
Accept-Encoding:
|
|
185
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
|
186
|
+
response:
|
|
187
|
+
status:
|
|
188
|
+
code: 200
|
|
189
|
+
message: OK
|
|
190
|
+
headers:
|
|
191
|
+
Content-Type:
|
|
192
|
+
- application/json
|
|
193
|
+
Date:
|
|
194
|
+
- Wed, 08 Jul 2026 12:02:02 GMT
|
|
195
|
+
Content-Length:
|
|
196
|
+
- '250'
|
|
197
|
+
body:
|
|
198
|
+
encoding: UTF-8
|
|
199
|
+
string: '{"kind":"APIGroup","apiVersion":"v1","name":"kubevirt.io","versions":[{"groupVersion":"kubevirt.io/v1","version":"v1"},{"groupVersion":"kubevirt.io/v1alpha3","version":"v1alpha3"}],"preferredVersion":{"groupVersion":"kubevirt.io/v1","version":"v1"}}
|
|
200
|
+
|
|
201
|
+
'
|
|
202
|
+
recorded_at: Wed, 08 Jul 2026 12:02:02 GMT
|
|
203
|
+
- request:
|
|
204
|
+
method: get
|
|
205
|
+
uri: https://10.8.254.82:8443/apis/kubevirt.io/v1/namespaces/default/virtualmachines/test2
|
|
206
|
+
body:
|
|
207
|
+
encoding: US-ASCII
|
|
208
|
+
string: ''
|
|
209
|
+
headers:
|
|
210
|
+
Accept:
|
|
211
|
+
- "*/*"
|
|
212
|
+
User-Agent:
|
|
213
|
+
- rest-client/2.1.0 (linux x86_64) ruby/3.3.11p205
|
|
214
|
+
Authorization:
|
|
215
|
+
- Bearer <TOKEN>
|
|
216
|
+
Accept-Encoding:
|
|
217
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
|
218
|
+
response:
|
|
219
|
+
status:
|
|
220
|
+
code: 200
|
|
221
|
+
message: OK
|
|
222
|
+
headers:
|
|
223
|
+
Content-Type:
|
|
224
|
+
- application/json
|
|
225
|
+
Date:
|
|
226
|
+
- Wed, 08 Jul 2026 12:02:02 GMT
|
|
227
|
+
Transfer-Encoding:
|
|
228
|
+
- chunked
|
|
229
|
+
body:
|
|
230
|
+
encoding: UTF-8
|
|
231
|
+
string: '{"apiVersion":"kubevirt.io/v1","kind":"VirtualMachine","metadata":{"annotations":{"kubevirt.io/latest-observed-api-version":"v1","kubevirt.io/storage-observed-api-version":"v1"},"creationTimestamp":"2026-07-08T12:02:02Z","finalizers":["kubevirt.io/virtualMachineControllerFinalize"],"generation":1,"labels":{"kubevirt.io/vm":"test2"},"managedFields":[{"apiVersion":"kubevirt.io/v1","fieldsType":"FieldsV1","fieldsV1":{"f:metadata":{"f:labels":{".":{},"f:kubevirt.io/vm":{}}},"f:spec":{".":{},"f:running":{},"f:template":{".":{},"f:metadata":{".":{},"f:creationTimestamp":{},"f:labels":{".":{},"f:kubevirt.io/vm":{}}},"f:spec":{".":{},"f:domain":{".":{},"f:cpu":{".":{},"f:cores":{}},"f:devices":{".":{},"f:disks":{}},"f:firmware":{".":{},"f:bootloader":{".":{},"f:efi":{".":{},"f:secureBoot":{}}}},"f:machine":{".":{},"f:type":{}},"f:resources":{".":{},"f:requests":{".":{},"f:memory":{}}}},"f:terminationGracePeriodSeconds":{},"f:volumes":{}}}}},"manager":"rest-client","operation":"Update","time":"2026-07-08T12:02:02Z"},{"apiVersion":"kubevirt.io/v1","fieldsType":"FieldsV1","fieldsV1":{"f:metadata":{"f:annotations":{".":{},"f:kubevirt.io/latest-observed-api-version":{},"f:kubevirt.io/storage-observed-api-version":{}},"f:finalizers":{".":{},"v:\"kubevirt.io/virtualMachineControllerFinalize\"":{}}}},"manager":"virt-controller","operation":"Update","time":"2026-07-08T12:02:02Z"},{"apiVersion":"kubevirt.io/v1","fieldsType":"FieldsV1","fieldsV1":{"f:status":{".":{},"f:conditions":{},"f:printableStatus":{},"f:volumeSnapshotStatuses":{}}},"manager":"virt-controller","operation":"Update","subresource":"status","time":"2026-07-08T12:02:02Z"}],"name":"test2","namespace":"default","resourceVersion":"4960050329","uid":"2ee29c23-80b5-420c-b718-ea28414ddc4c"},"spec":{"running":false,"template":{"metadata":{"annotations":{"kubevirt.io/pci-topology-version":"v3"},"labels":{"kubevirt.io/vm":"test2"}},"spec":{"architecture":"amd64","domain":{"cpu":{"cores":1},"devices":{"disks":[{"disk":{"bus":"virtio"},"name":"test2-disk-00"}]},"firmware":{"bootloader":{"efi":{"secureBoot":false}},"serial":"8c595911-21bf-4712-a443-a10914cf9dea","uuid":"5bcd429a-9f7f-4c5a-87fd-51ac744334bf"},"machine":{"type":"q35"},"resources":{"requests":{"memory":"64M"}}},"terminationGracePeriodSeconds":0,"volumes":[{"name":"test2-disk-00","persistentVolumeClaim":{"claimName":"mypvc3"}}]}}},"status":{"conditions":[{"lastProbeTime":"2026-07-08T12:02:02Z","lastTransitionTime":"2026-07-08T12:02:02Z","message":"VMI
|
|
232
|
+
does not exist","reason":"VMINotExists","status":"False","type":"Ready"}],"printableStatus":"Stopped","volumeSnapshotStatuses":[{"enabled":false,"name":"test2-disk-00","reason":"No
|
|
233
|
+
VolumeSnapshotClass: Volume snapshots are not configured for this StorageClass
|
|
234
|
+
[local-storage] [test2-disk-00]"}]}}
|
|
235
|
+
|
|
236
|
+
'
|
|
237
|
+
recorded_at: Wed, 08 Jul 2026 12:02:02 GMT
|
|
238
|
+
- request:
|
|
239
|
+
method: get
|
|
240
|
+
uri: https://10.8.254.82:8443/api
|
|
241
|
+
body:
|
|
242
|
+
encoding: US-ASCII
|
|
243
|
+
string: ''
|
|
244
|
+
headers:
|
|
245
|
+
Accept:
|
|
246
|
+
- "*/*"
|
|
247
|
+
User-Agent:
|
|
248
|
+
- rest-client/2.1.0 (linux x86_64) ruby/3.3.11p205
|
|
249
|
+
Authorization:
|
|
250
|
+
- Bearer <TOKEN>
|
|
251
|
+
Accept-Encoding:
|
|
252
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
|
253
|
+
response:
|
|
254
|
+
status:
|
|
255
|
+
code: 200
|
|
256
|
+
message: OK
|
|
257
|
+
headers:
|
|
258
|
+
Content-Type:
|
|
259
|
+
- application/json
|
|
260
|
+
Date:
|
|
261
|
+
- Wed, 08 Jul 2026 12:02:02 GMT
|
|
262
|
+
Content-Length:
|
|
263
|
+
- '138'
|
|
264
|
+
body:
|
|
265
|
+
encoding: UTF-8
|
|
266
|
+
string: '{"kind":"APIVersions","versions":["v1"],"serverAddressByClientCIDRs":[{"clientCIDR":"0.0.0.0/0","serverAddress":"130.236.252.121:8443"}]}
|
|
267
|
+
|
|
268
|
+
'
|
|
269
|
+
recorded_at: Wed, 08 Jul 2026 12:02:02 GMT
|
|
270
|
+
- request:
|
|
271
|
+
method: get
|
|
272
|
+
uri: https://10.8.254.82:8443/api/v1
|
|
273
|
+
body:
|
|
274
|
+
encoding: US-ASCII
|
|
275
|
+
string: ''
|
|
276
|
+
headers:
|
|
277
|
+
Accept:
|
|
278
|
+
- "*/*"
|
|
279
|
+
User-Agent:
|
|
280
|
+
- rest-client/2.1.0 (linux x86_64) ruby/3.3.11p205
|
|
281
|
+
Authorization:
|
|
282
|
+
- Bearer <TOKEN>
|
|
283
|
+
Accept-Encoding:
|
|
284
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
|
285
|
+
response:
|
|
286
|
+
status:
|
|
287
|
+
code: 200
|
|
288
|
+
message: OK
|
|
289
|
+
headers:
|
|
290
|
+
Content-Type:
|
|
291
|
+
- application/json
|
|
292
|
+
Date:
|
|
293
|
+
- Wed, 08 Jul 2026 12:02:02 GMT
|
|
294
|
+
Transfer-Encoding:
|
|
295
|
+
- chunked
|
|
296
|
+
body:
|
|
297
|
+
encoding: UTF-8
|
|
298
|
+
string: '{"kind":"APIResourceList","groupVersion":"v1","resources":[{"name":"bindings","singularName":"binding","namespaced":true,"kind":"Binding","verbs":["create"]},{"name":"componentstatuses","singularName":"componentstatus","namespaced":false,"kind":"ComponentStatus","verbs":["get","list"],"shortNames":["cs"]},{"name":"configmaps","singularName":"configmap","namespaced":true,"kind":"ConfigMap","verbs":["create","delete","deletecollection","get","list","patch","update","watch"],"shortNames":["cm"],"storageVersionHash":"qFsyl6wFWjQ="},{"name":"endpoints","singularName":"endpoints","namespaced":true,"kind":"Endpoints","verbs":["create","delete","deletecollection","get","list","patch","update","watch"],"shortNames":["ep"],"storageVersionHash":"fWeeMqaN/OA="},{"name":"events","singularName":"event","namespaced":true,"kind":"Event","verbs":["create","delete","deletecollection","get","list","patch","update","watch"],"shortNames":["ev"],"storageVersionHash":"r2yiGXH7wu8="},{"name":"limitranges","singularName":"limitrange","namespaced":true,"kind":"LimitRange","verbs":["create","delete","deletecollection","get","list","patch","update","watch"],"shortNames":["limits"],"storageVersionHash":"EBKMFVe6cwo="},{"name":"namespaces","singularName":"namespace","namespaced":false,"kind":"Namespace","verbs":["create","delete","get","list","patch","update","watch"],"shortNames":["ns"],"storageVersionHash":"Q3oi5N2YM8M="},{"name":"namespaces/finalize","singularName":"","namespaced":false,"kind":"Namespace","verbs":["update"]},{"name":"namespaces/status","singularName":"","namespaced":false,"kind":"Namespace","verbs":["get","patch","update"]},{"name":"nodes","singularName":"node","namespaced":false,"kind":"Node","verbs":["create","delete","deletecollection","get","list","patch","update","watch"],"shortNames":["no"],"storageVersionHash":"XwShjMxG9Fs="},{"name":"nodes/proxy","singularName":"","namespaced":false,"kind":"NodeProxyOptions","verbs":["create","delete","get","patch","update"]},{"name":"nodes/status","singularName":"","namespaced":false,"kind":"Node","verbs":["get","patch","update"]},{"name":"persistentvolumeclaims","singularName":"persistentvolumeclaim","namespaced":true,"kind":"PersistentVolumeClaim","verbs":["create","delete","deletecollection","get","list","patch","update","watch"],"shortNames":["pvc"],"storageVersionHash":"QWTyNDq0dC4="},{"name":"persistentvolumeclaims/status","singularName":"","namespaced":true,"kind":"PersistentVolumeClaim","verbs":["get","patch","update"]},{"name":"persistentvolumes","singularName":"persistentvolume","namespaced":false,"kind":"PersistentVolume","verbs":["create","delete","deletecollection","get","list","patch","update","watch"],"shortNames":["pv"],"storageVersionHash":"HN/zwEC+JgM="},{"name":"persistentvolumes/status","singularName":"","namespaced":false,"kind":"PersistentVolume","verbs":["get","patch","update"]},{"name":"pods","singularName":"pod","namespaced":true,"kind":"Pod","verbs":["create","delete","deletecollection","get","list","patch","update","watch"],"shortNames":["po"],"categories":["all"],"storageVersionHash":"xPOwRZ+Yhw8="},{"name":"pods/attach","singularName":"","namespaced":true,"kind":"PodAttachOptions","verbs":["create","get"]},{"name":"pods/binding","singularName":"","namespaced":true,"kind":"Binding","verbs":["create"]},{"name":"pods/ephemeralcontainers","singularName":"","namespaced":true,"kind":"Pod","verbs":["get","patch","update"]},{"name":"pods/eviction","singularName":"","namespaced":true,"group":"policy","version":"v1","kind":"Eviction","verbs":["create"]},{"name":"pods/exec","singularName":"","namespaced":true,"kind":"PodExecOptions","verbs":["create","get"]},{"name":"pods/log","singularName":"","namespaced":true,"kind":"Pod","verbs":["get"]},{"name":"pods/portforward","singularName":"","namespaced":true,"kind":"PodPortForwardOptions","verbs":["create","get"]},{"name":"pods/proxy","singularName":"","namespaced":true,"kind":"PodProxyOptions","verbs":["create","delete","get","patch","update"]},{"name":"pods/resize","singularName":"","namespaced":true,"kind":"Pod","verbs":["get","patch","update"]},{"name":"pods/status","singularName":"","namespaced":true,"kind":"Pod","verbs":["get","patch","update"]},{"name":"podtemplates","singularName":"podtemplate","namespaced":true,"kind":"PodTemplate","verbs":["create","delete","deletecollection","get","list","patch","update","watch"],"storageVersionHash":"LIXB2x4IFpk="},{"name":"replicationcontrollers","singularName":"replicationcontroller","namespaced":true,"kind":"ReplicationController","verbs":["create","delete","deletecollection","get","list","patch","update","watch"],"shortNames":["rc"],"categories":["all"],"storageVersionHash":"Jond2If31h0="},{"name":"replicationcontrollers/scale","singularName":"","namespaced":true,"group":"autoscaling","version":"v1","kind":"Scale","verbs":["get","patch","update"]},{"name":"replicationcontrollers/status","singularName":"","namespaced":true,"kind":"ReplicationController","verbs":["get","patch","update"]},{"name":"resourcequotas","singularName":"resourcequota","namespaced":true,"kind":"ResourceQuota","verbs":["create","delete","deletecollection","get","list","patch","update","watch"],"shortNames":["quota"],"storageVersionHash":"8uhSgffRX6w="},{"name":"resourcequotas/status","singularName":"","namespaced":true,"kind":"ResourceQuota","verbs":["get","patch","update"]},{"name":"secrets","singularName":"secret","namespaced":true,"kind":"Secret","verbs":["create","delete","deletecollection","get","list","patch","update","watch"],"storageVersionHash":"S6u1pOWzb84="},{"name":"serviceaccounts","singularName":"serviceaccount","namespaced":true,"kind":"ServiceAccount","verbs":["create","delete","deletecollection","get","list","patch","update","watch"],"shortNames":["sa"],"storageVersionHash":"pbx9ZvyFpBE="},{"name":"serviceaccounts/token","singularName":"","namespaced":true,"group":"authentication.k8s.io","version":"v1","kind":"TokenRequest","verbs":["create"]},{"name":"services","singularName":"service","namespaced":true,"kind":"Service","verbs":["create","delete","deletecollection","get","list","patch","update","watch"],"shortNames":["svc"],"categories":["all"],"storageVersionHash":"0/CO1lhkEBI="},{"name":"services/proxy","singularName":"","namespaced":true,"kind":"ServiceProxyOptions","verbs":["create","delete","get","patch","update"]},{"name":"services/status","singularName":"","namespaced":true,"kind":"Service","verbs":["get","patch","update"]}]}
|
|
299
|
+
|
|
300
|
+
'
|
|
301
|
+
recorded_at: Wed, 08 Jul 2026 12:02:02 GMT
|
|
302
|
+
- request:
|
|
303
|
+
method: get
|
|
304
|
+
uri: https://10.8.254.82:8443/api/v1/namespaces/default/persistentvolumeclaims/mypvc3
|
|
305
|
+
body:
|
|
306
|
+
encoding: US-ASCII
|
|
307
|
+
string: ''
|
|
308
|
+
headers:
|
|
309
|
+
Accept:
|
|
310
|
+
- "*/*"
|
|
311
|
+
User-Agent:
|
|
312
|
+
- rest-client/2.1.0 (linux x86_64) ruby/3.3.11p205
|
|
313
|
+
Authorization:
|
|
314
|
+
- Bearer <TOKEN>
|
|
315
|
+
Accept-Encoding:
|
|
316
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
|
317
|
+
response:
|
|
318
|
+
status:
|
|
319
|
+
code: 200
|
|
320
|
+
message: OK
|
|
321
|
+
headers:
|
|
322
|
+
Content-Type:
|
|
323
|
+
- application/json
|
|
324
|
+
Date:
|
|
325
|
+
- Wed, 08 Jul 2026 12:02:02 GMT
|
|
326
|
+
Content-Length:
|
|
327
|
+
- '1716'
|
|
328
|
+
body:
|
|
329
|
+
encoding: UTF-8
|
|
330
|
+
string: '{"kind":"PersistentVolumeClaim","apiVersion":"v1","metadata":{"name":"mypvc3","namespace":"default","uid":"863e66c5-ba35-4aa3-9b20-01eeda883020","resourceVersion":"4960017312","creationTimestamp":"2026-07-08T11:35:08Z","annotations":{"pv.kubernetes.io/bind-completed":"yes","pv.kubernetes.io/bound-by-controller":"yes","volume.beta.kubernetes.io/storage-provisioner":"local-storage","volume.kubernetes.io/storage-provisioner":"local-storage"},"finalizers":["kubernetes.io/pvc-protection"],"managedFields":[{"manager":"kubectl-create","operation":"Update","apiVersion":"v1","time":"2026-07-08T11:35:08Z","fieldsType":"FieldsV1","fieldsV1":{"f:spec":{"f:accessModes":{},"f:resources":{"f:requests":{".":{},"f:storage":{}}},"f:volumeMode":{}}}},{"manager":"kube-controller-manager","operation":"Update","apiVersion":"v1","time":"2026-07-08T11:35:09Z","fieldsType":"FieldsV1","fieldsV1":{"f:metadata":{"f:annotations":{".":{},"f:pv.kubernetes.io/bind-completed":{},"f:pv.kubernetes.io/bound-by-controller":{},"f:volume.beta.kubernetes.io/storage-provisioner":{},"f:volume.kubernetes.io/storage-provisioner":{}}},"f:spec":{"f:volumeName":{}}}},{"manager":"kube-controller-manager","operation":"Update","apiVersion":"v1","time":"2026-07-08T11:35:09Z","fieldsType":"FieldsV1","fieldsV1":{"f:status":{"f:accessModes":{},"f:capacity":{".":{},"f:storage":{}},"f:phase":{}}},"subresource":"status"}]},"spec":{"accessModes":["ReadWriteOnce"],"resources":{"requests":{"storage":"1Mi"}},"volumeName":"pvc-863e66c5-ba35-4aa3-9b20-01eeda883020","storageClassName":"local-storage","volumeMode":"Filesystem"},"status":{"phase":"Bound","accessModes":["ReadWriteOnce"],"capacity":{"storage":"1Mi"}}}
|
|
331
|
+
|
|
332
|
+
'
|
|
333
|
+
recorded_at: Wed, 08 Jul 2026 12:02:02 GMT
|
|
334
|
+
- request:
|
|
335
|
+
method: get
|
|
336
|
+
uri: https://10.8.254.82:8443/apis/kubevirt.io
|
|
337
|
+
body:
|
|
338
|
+
encoding: US-ASCII
|
|
339
|
+
string: ''
|
|
340
|
+
headers:
|
|
341
|
+
Accept:
|
|
342
|
+
- "*/*"
|
|
343
|
+
User-Agent:
|
|
344
|
+
- rest-client/2.1.0 (linux x86_64) ruby/3.3.11p205
|
|
345
|
+
Authorization:
|
|
346
|
+
- Bearer <TOKEN>
|
|
347
|
+
Accept-Encoding:
|
|
348
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
|
349
|
+
response:
|
|
350
|
+
status:
|
|
351
|
+
code: 200
|
|
352
|
+
message: OK
|
|
353
|
+
headers:
|
|
354
|
+
Content-Type:
|
|
355
|
+
- application/json
|
|
356
|
+
Date:
|
|
357
|
+
- Wed, 08 Jul 2026 12:02:02 GMT
|
|
358
|
+
Content-Length:
|
|
359
|
+
- '250'
|
|
360
|
+
body:
|
|
361
|
+
encoding: UTF-8
|
|
362
|
+
string: '{"kind":"APIGroup","apiVersion":"v1","name":"kubevirt.io","versions":[{"groupVersion":"kubevirt.io/v1","version":"v1"},{"groupVersion":"kubevirt.io/v1alpha3","version":"v1alpha3"}],"preferredVersion":{"groupVersion":"kubevirt.io/v1","version":"v1"}}
|
|
363
|
+
|
|
364
|
+
'
|
|
365
|
+
recorded_at: Wed, 08 Jul 2026 12:02:02 GMT
|
|
366
|
+
- request:
|
|
367
|
+
method: delete
|
|
368
|
+
uri: https://10.8.254.82:8443/apis/kubevirt.io/v1/namespaces/default/virtualmachines/test2
|
|
369
|
+
body:
|
|
370
|
+
encoding: US-ASCII
|
|
371
|
+
string: ''
|
|
372
|
+
headers:
|
|
373
|
+
Accept:
|
|
374
|
+
- "*/*"
|
|
375
|
+
User-Agent:
|
|
376
|
+
- rest-client/2.1.0 (linux x86_64) ruby/3.3.11p205
|
|
377
|
+
Content-Type:
|
|
378
|
+
- application/json
|
|
379
|
+
Authorization:
|
|
380
|
+
- Bearer <TOKEN>
|
|
381
|
+
Accept-Encoding:
|
|
382
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
|
383
|
+
response:
|
|
384
|
+
status:
|
|
385
|
+
code: 200
|
|
386
|
+
message: OK
|
|
387
|
+
headers:
|
|
388
|
+
Content-Type:
|
|
389
|
+
- application/json
|
|
390
|
+
Date:
|
|
391
|
+
- Wed, 08 Jul 2026 12:02:02 GMT
|
|
392
|
+
Transfer-Encoding:
|
|
393
|
+
- chunked
|
|
394
|
+
body:
|
|
395
|
+
encoding: UTF-8
|
|
396
|
+
string: '{"apiVersion":"kubevirt.io/v1","kind":"VirtualMachine","metadata":{"annotations":{"kubevirt.io/latest-observed-api-version":"v1","kubevirt.io/storage-observed-api-version":"v1"},"creationTimestamp":"2026-07-08T12:02:02Z","deletionGracePeriodSeconds":0,"deletionTimestamp":"2026-07-08T12:02:02Z","finalizers":["kubevirt.io/virtualMachineControllerFinalize"],"generation":2,"labels":{"kubevirt.io/vm":"test2"},"managedFields":[{"apiVersion":"kubevirt.io/v1","fieldsType":"FieldsV1","fieldsV1":{"f:metadata":{"f:labels":{".":{},"f:kubevirt.io/vm":{}}},"f:spec":{".":{},"f:running":{},"f:template":{".":{},"f:metadata":{".":{},"f:creationTimestamp":{},"f:labels":{".":{},"f:kubevirt.io/vm":{}}},"f:spec":{".":{},"f:domain":{".":{},"f:cpu":{".":{},"f:cores":{}},"f:devices":{".":{},"f:disks":{}},"f:firmware":{".":{},"f:bootloader":{".":{},"f:efi":{".":{},"f:secureBoot":{}}}},"f:machine":{".":{},"f:type":{}},"f:resources":{".":{},"f:requests":{".":{},"f:memory":{}}}},"f:terminationGracePeriodSeconds":{},"f:volumes":{}}}}},"manager":"rest-client","operation":"Update","time":"2026-07-08T12:02:02Z"},{"apiVersion":"kubevirt.io/v1","fieldsType":"FieldsV1","fieldsV1":{"f:metadata":{"f:annotations":{".":{},"f:kubevirt.io/latest-observed-api-version":{},"f:kubevirt.io/storage-observed-api-version":{}},"f:finalizers":{".":{},"v:\"kubevirt.io/virtualMachineControllerFinalize\"":{}}}},"manager":"virt-controller","operation":"Update","time":"2026-07-08T12:02:02Z"},{"apiVersion":"kubevirt.io/v1","fieldsType":"FieldsV1","fieldsV1":{"f:status":{".":{},"f:conditions":{},"f:printableStatus":{},"f:volumeSnapshotStatuses":{}}},"manager":"virt-controller","operation":"Update","subresource":"status","time":"2026-07-08T12:02:02Z"}],"name":"test2","namespace":"default","resourceVersion":"4960050336","uid":"2ee29c23-80b5-420c-b718-ea28414ddc4c"},"spec":{"running":false,"template":{"metadata":{"annotations":{"kubevirt.io/pci-topology-version":"v3"},"labels":{"kubevirt.io/vm":"test2"}},"spec":{"architecture":"amd64","domain":{"cpu":{"cores":1},"devices":{"disks":[{"disk":{"bus":"virtio"},"name":"test2-disk-00"}]},"firmware":{"bootloader":{"efi":{"secureBoot":false}},"serial":"8c595911-21bf-4712-a443-a10914cf9dea","uuid":"5bcd429a-9f7f-4c5a-87fd-51ac744334bf"},"machine":{"type":"q35"},"resources":{"requests":{"memory":"64M"}}},"terminationGracePeriodSeconds":0,"volumes":[{"name":"test2-disk-00","persistentVolumeClaim":{"claimName":"mypvc3"}}]}}},"status":{"conditions":[{"lastProbeTime":"2026-07-08T12:02:02Z","lastTransitionTime":"2026-07-08T12:02:02Z","message":"VMI
|
|
397
|
+
does not exist","reason":"VMINotExists","status":"False","type":"Ready"}],"printableStatus":"Stopped","volumeSnapshotStatuses":[{"enabled":false,"name":"test2-disk-00","reason":"No
|
|
398
|
+
VolumeSnapshotClass: Volume snapshots are not configured for this StorageClass
|
|
399
|
+
[local-storage] [test2-disk-00]"}]}}
|
|
400
|
+
|
|
401
|
+
'
|
|
402
|
+
recorded_at: Wed, 08 Jul 2026 12:02:02 GMT
|
|
403
|
+
recorded_with: VCR 6.4.0
|
data/spec/unit/create_vm_spec.rb
CHANGED
|
@@ -129,6 +129,28 @@ describe Fog::Compute do
|
|
|
129
129
|
end
|
|
130
130
|
end
|
|
131
131
|
|
|
132
|
+
it 'creates EFI vm' do
|
|
133
|
+
VCR.use_cassette("vm_create_efi") do
|
|
134
|
+
begin
|
|
135
|
+
vm_name = 'test2'
|
|
136
|
+
cpus = 1
|
|
137
|
+
memory_size = '64'
|
|
138
|
+
memory_unit = 'M'
|
|
139
|
+
|
|
140
|
+
volume = Fog::Kubevirt::Compute::Volume.new
|
|
141
|
+
volume.type = 'persistentVolumeClaim'
|
|
142
|
+
volume.info = 'mypvc3'
|
|
143
|
+
@service.vms.create(vm_name: vm_name, cpus: cpus, memory_size: memory_size, memory_unit: memory_unit, volumes: [volume], extra_domain: { firmware: { bootloader: { efi: { secureBoot: false } } } })
|
|
144
|
+
|
|
145
|
+
vm = @service.vms.get(vm_name)
|
|
146
|
+
|
|
147
|
+
assert_equal(vm.bootloader.keys.first, :efi)
|
|
148
|
+
ensure
|
|
149
|
+
@service.vms.delete(vm_name) if vm
|
|
150
|
+
end
|
|
151
|
+
end
|
|
152
|
+
end
|
|
153
|
+
|
|
132
154
|
it 'creates vm with single userdata secret' do
|
|
133
155
|
VCR.use_cassette("vm_create_single_userdata") do
|
|
134
156
|
begin
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: fog-kubevirt
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.
|
|
4
|
+
version: 1.8.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Piotr Kliczewski
|
|
@@ -17,6 +17,7 @@ authors:
|
|
|
17
17
|
- Arvind Jangir
|
|
18
18
|
- Evgeni Golov
|
|
19
19
|
- Shim Shtein
|
|
20
|
+
- Alexander Olofsson
|
|
20
21
|
- Wesley Beary
|
|
21
22
|
bindir: bin
|
|
22
23
|
cert_chain: []
|
|
@@ -155,6 +156,7 @@ email:
|
|
|
155
156
|
- ajangir@ajangir-thinkpadt14gen5.punetw6.csb
|
|
156
157
|
- evgeni@golov.de
|
|
157
158
|
- sshtein@redhat.com
|
|
159
|
+
- alexander.olofsson@liu.se
|
|
158
160
|
- geemus@gmail.com
|
|
159
161
|
executables: []
|
|
160
162
|
extensions: []
|
|
@@ -250,6 +252,7 @@ files:
|
|
|
250
252
|
- spec/fixtures/kubevirt/service/services_crud.yml
|
|
251
253
|
- spec/fixtures/kubevirt/storageclass/storageclasses_crud.yml
|
|
252
254
|
- spec/fixtures/kubevirt/vm/vm_create_datavolumetemplate.yml
|
|
255
|
+
- spec/fixtures/kubevirt/vm/vm_create_efi.yml
|
|
253
256
|
- spec/fixtures/kubevirt/vm/vm_create_multi.yml
|
|
254
257
|
- spec/fixtures/kubevirt/vm/vm_create_single.yml
|
|
255
258
|
- spec/fixtures/kubevirt/vm/vm_create_single_userdata.yml
|
|
@@ -306,6 +309,7 @@ test_files:
|
|
|
306
309
|
- spec/fixtures/kubevirt/service/services_crud.yml
|
|
307
310
|
- spec/fixtures/kubevirt/storageclass/storageclasses_crud.yml
|
|
308
311
|
- spec/fixtures/kubevirt/vm/vm_create_datavolumetemplate.yml
|
|
312
|
+
- spec/fixtures/kubevirt/vm/vm_create_efi.yml
|
|
309
313
|
- spec/fixtures/kubevirt/vm/vm_create_multi.yml
|
|
310
314
|
- spec/fixtures/kubevirt/vm/vm_create_single.yml
|
|
311
315
|
- spec/fixtures/kubevirt/vm/vm_create_single_userdata.yml
|