-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathfedora.yaml.j2
More file actions
104 lines (104 loc) · 2.77 KB
/
Copy pathfedora.yaml.j2
File metadata and controls
104 lines (104 loc) · 2.77 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
apiVersion: kubevirt.io/v1
kind: VirtualMachine
metadata:
annotations:
vm.kubevirt.io/os: fedora
vm.kubevirt.io/workload: highperformance
labels:
kubevirt.io/domain: {{vm_name}}
network.kubevirt.io/headlessService: headless
name: {{vm_name}}
namespace: simple-fio
spec:
dataVolumeTemplates:
- apiVersion: cdi.kubevirt.io/v1beta1
kind: DataVolume
metadata:
name: {{dv_name}}
spec:
source:
http:
#url: http://dl.fedoraproject.org/pub/fedora/linux/releases/41/Cloud/x86_64/images/Fedora-Cloud-Base-Generic-41-1.4.x86_64.qcow2
url: http://dl.fedoraproject.org/pub/fedora/linux/releases/43/Cloud/x86_64/images/Fedora-Cloud-Base-Generic-43-1.6.x86_64.qcow2
storage:
accessModes:
- {{access_mode | default('ReadWriteOnce')}}
resources:
requests:
storage: 50Gi
volumeMode: {{volume_mode | default('Block')}}
storageClassName: {{sc_name}}
accessCredentials:
- sshPublicKey:
propagationMethod:
noCloud: {}
runStrategy: RerunOnFailure
template:
metadata:
labels:
kubevirt.io/domain: {{vm_name}}
spec:
architecture: amd64
domain:
cpu:
cores: 1
sockets: 4
threads: 1
#maxSockets: 4
model: host-model
memory:
guest: 4Gi
resources:
requests:
memory: 4Gi
devices:
disks:
- disk:
bus: virtio
name: rootdisk
- disk:
bus: virtio
name: cloudinitdisk
interfaces:
- name: default
masquerade: {}
model: virtio
#- bridge: {}
#model: virtio
#name: nic-migration
rng: {}
features:
acpi:
enabled: true
smm:
enabled: true
firmware:
bootloader:
efi: {}
machine:
type: pc-q35-rhel9.4.0
evictionStrategy: LiveMigrate
networks:
- name: default
pod: {}
#- multus:
#networkName: vm-nad
#name: nic-migration
terminationGracePeriodSeconds: 180
volumes:
- dataVolume:
name: {{dv_name}}
name: rootdisk
- cloudInitNoCloud:
userData: |-
#cloud-config
user: fedora
password: fedora
chpasswd: { expire: False }
packages:
- fio
- wget
runcmd:
- [ wget, https://gist.githubusercontent.com/bose-abhishek/82143fe028599aac41e9fb0dbdf8ef95/raw/681c392e78694d65cd87128b39a83b4a6f4467c9/fio-startup-script.sh ]
- [ sh, fio-startup-script.sh ]
name: cloudinitdisk