Compare commits

..

65 commits

Author SHA1 Message Date
94a23cce8e feat(docker-image)!: Update quay.io/containerdisks/ubuntu Docker tag to v24 2025-07-22 11:13:55 +00:00
c84c1fcd78 Add test-connectivity 2025-07-22 13:02:04 +02:00
fb1c82659f Update kustomization 2025-07-22 12:50:57 +02:00
b15d8e6882 changed NAD to static to test 2025-07-22 12:16:37 +02:00
f76153ff5d new test of fortigate for KSD 2025-07-22 10:47:20 +02:00
9980d50b07 test with masq 2025-07-09 12:34:37 +02:00
6a719ccdc8 set SB to false 2025-07-09 12:08:25 +02:00
516c1bd034 added secure boot again 2025-07-09 12:07:05 +02:00
da7f7f73c1 added object 2025-07-09 12:02:58 +02:00
410cb99173 change port and add lb 2025-07-09 12:00:51 +02:00
4cf5bfcceb mutlus required 2025-07-08 17:58:30 +02:00
070ef198ed add networks 2025-07-08 17:50:44 +02:00
1e611e5621 added network defs 2025-07-08 17:40:47 +02:00
bd27459945 revert changes 2025-07-08 17:31:31 +02:00
8e7ea57673 multi interface test 2025-07-08 16:57:00 +02:00
1a44751d94 comment out secretref 2025-07-08 11:23:52 +02:00
32ff5115f0 change port and change https to http in URL 2025-07-04 13:48:07 +02:00
9532ba8fe8
Resolve conflict 2025-07-04 13:16:51 +02:00
883d8152b8
Use ip 2025-07-04 13:11:34 +02:00
284040d065
Use lb 2025-07-04 13:09:37 +02:00
de9f1d5014
Set proper domain 2025-07-04 13:01:28 +02:00
633f1ca564
Set external ingress classname for nginx 2025-07-04 12:59:34 +02:00
98ee757f94 changed secret reference to Old CDI format 2025-07-02 15:39:53 +02:00
eeaece034f added s3 secret base64 encoded and S3 Firewall 2025-07-02 15:18:01 +02:00
d5f8404835 changed to nginx image 2025-06-30 15:44:12 +02:00
b30d768472 forgot to change app name in ks file 2025-06-30 15:39:02 +02:00
8862ff90eb Added firewall test deploy from S3 Bucket 2025-06-30 11:48:40 +02:00
628d1de0e3 removed unneccessary settings and SMM 2025-06-25 11:09:35 +02:00
4ac200e1dc Added fortios to VM for testing 2025-06-25 11:01:17 +02:00
ad92d3393a define secure boot boolean 2025-06-24 16:31:18 +02:00
49c60fe87e Changed back to original code 2025-06-24 16:27:11 +02:00
be88f635f1 changed smm to enabled (Secureboot) 2025-06-24 12:20:36 +02:00
1118c89f66 change to match redhat documentation 2025-06-24 12:15:24 +02:00
7134c2d905 wrong volume name 2025-06-24 12:07:14 +02:00
989a3467be comment out driver disk 2025-06-24 12:05:27 +02:00
dc6e4274dd changed bus type again 2025-06-24 12:02:01 +02:00
29d8d2fed2 Issue with Datasource 2025-06-24 11:51:08 +02:00
631b4a1ede changed running strategy and changed labels 2025-06-24 10:52:13 +02:00
84bd7195fc delete k record vm 1 2025-06-24 10:45:11 +02:00
1b8a324f7e added datasource 2025-06-02 12:43:21 +02:00
c32ae8b40a removed old method and added new test vm 2025-05-30 12:41:29 +02:00
4c5a76347d enable smm 2025-05-28 15:52:26 +02:00
64458e5bad smm disable 2025-05-28 15:50:38 +02:00
4d2924f7d4 improvements 2025-05-28 15:07:50 +02:00
63019b6529 put into wrong category 2025-05-28 15:01:45 +02:00
bfd039dd32 indent even better 2025-05-28 14:58:00 +02:00
55105e3704 indent better 2025-05-28 14:55:08 +02:00
aacdc46fb0 indent 2025-05-28 14:51:35 +02:00
387d3e65bf remove model 2025-05-28 14:47:23 +02:00
bd1784429c added efi bootloader 2025-05-28 14:46:02 +02:00
99076daf8e rootdisk to virtio 2025-05-28 14:11:27 +02:00
ca3e37e667 changed volume mode 2025-05-28 13:10:59 +02:00
87de70c51e block storage not supported on AI 2 2025-05-28 13:06:26 +02:00
5e7cad0edc larger rootdisk size 2025-05-28 12:49:42 +02:00
78d1e0d3ab Increase rootdisk size 2025-05-28 12:37:01 +02:00
0f54f22879 comment out disk for cloud init 2025-05-28 12:01:17 +02:00
1604b7e613 indent 2025-05-28 11:58:32 +02:00
9b64dfad0b mistake in disc allocation 2025-05-28 11:53:28 +02:00
86f10cbd6d changed label 2025-05-28 11:46:58 +02:00
6a78fbf5c0 Added Kustomizations 2025-05-28 11:45:59 +02:00
4fda3a9eff Added New VM and Load Balancer 2025-05-28 09:56:07 +02:00
d638ec4c45 changed parameter to values 2025-05-12 15:02:32 +02:00
e2fb066279 added windows machine via flux 2025-05-12 14:57:27 +02:00
6abfc970df changed image 2025-05-09 12:47:52 +02:00
1f600af0f4 added new image 2025-05-08 18:14:39 +02:00
27 changed files with 824 additions and 11 deletions

18
firewall-s3/ks-vm.yaml Normal file
View file

@ -0,0 +1,18 @@
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
metadata:
name: &app fortigate-s3
namespace: ${TENANT_NAMESPACE}
spec:
commonMetadata:
labels:
app.kubernetes.io/name: *app
path: ./firewall-s3
prune: true
sourceRef:
kind: GitRepository
name: tenant-repos
wait: false
interval: 30m
retryInterval: 1m
timeout: 5m

View file

@ -0,0 +1,30 @@
---
apiVersion: v1
kind: Service
metadata:
name: fortigate-lb-test
namespace: ${TENANT_NAMESPACE}
labels:
app.kubernetes.io/component: fortigate-lb
spec:
type: LoadBalancer
externalTrafficPolicy: Local
ports:
- port: 4500
name: ipsec-nat
targetPort: 4500
protocol: UDP
- port: 500
name: key-management
targetPort: 500
protocol: UDP
#- port: 22
# name: ssh
# targetPort: 22
# protocol: TCP
- port: 443
name: https
targetPort: 443
protocol: TCP
selector:
kubevirt.io/domain: fortigate-ksd

View file

@ -0,0 +1,20 @@
# apiVersion: "k8s.cni.cncf.io/v1"
# kind: NetworkAttachmentDefinition
# metadata:
# name: lan-net
# namespace: ${TENANT_NAMESPACE}
# spec:
# config: '{
# "cniVersion": "0.3.1",
# "type": "bridge",
# "bridge": "br-lan",
# "ipam": {
# "type": "static",
# "addresses": [
# {
# "address": "172.168.100.2/24",
# "gateway": "172.168.100.1"
# }
# ]
# }
# }'

View file

@ -0,0 +1,20 @@
# apiVersion: "k8s.cni.cncf.io/v1"
# kind: NetworkAttachmentDefinition
# metadata:
# name: mgmt-net
# namespace: ${TENANT_NAMESPACE}
# spec:
# config: '{
# "cniVersion": "0.3.1",
# "type": "bridge",
# "bridge": "br-mgmt",
# "ipam": {
# "type": "static",
# "addresses": [
# {
# "address": "192.168.10.100/24",
# "gateway": "192.168.10.1"
# }
# ]
# }
# }'

View file

@ -0,0 +1,77 @@
# apiVersion: kubevirt.io/v1
# kind: VirtualMachine
# metadata:
# name: fortigate-ksd
# namespace: ${TENANT_NAMESPACE}
# spec:
# dataVolumeTemplates:
# - metadata:
# name: fortigate-rootdisk-ksd
# spec:
# source:
# http:
# url: "https://glacier-1.kvant.cloud/ocp-virt-images/sources/fortios_7_6_3.qcow2"
# #secretRef: s3-virt-credentials
# storage:
# resources:
# requests:
# storage: 30Gi
# runStrategy: Always
# template:
# metadata:
# labels:
# kubevirt.io/domain: fortigate-ksd
# spec:
# domain:
# cpu:
# cores: 1
# memory:
# guest: 2Gi
# features:
# acpi: {}
# smm:
# enabled: true
# firmware:
# bootloader:
# efi:
# secureBoot: false
# devices:
# rng: {}
# networkInterfaceMultiqueue: true
# interfaces:
# - name: wan
# masquerade: {}
# ports:
# - port: 4500
# - port: 443
# - port: 22
# - port: 500
# - name: mgmt
# bridge: {}
# - name: lan
# bridge: {}
# disks:
# - disk:
# bus: sata
# name: rootdisk
# resources:
# requests:
# memory: 2Gi
# cpu: 1
# limits:
# memory: 2Gi
# cpu: 1
# networks:
# - name: wan
# pod: {}
# - name: mgmt
# multus:
# networkName: ${TENANT_NAMESPACE}/mgmt-net
# - name: lan
# multus:
# networkName: ${TENANT_NAMESPACE}/lan-net
# terminationGracePeriodSeconds: 180
# volumes:
# - name: rootdisk
# dataVolume:
# name: fortigate-rootdisk-ksd

View file

@ -0,0 +1,73 @@
# apiVersion: kubevirt.io/v1
# kind: VirtualMachine
# metadata:
# name: strongswan
# namespace: ${TENANT_NAMESPACE}
# spec:
# running: true
# template:
# metadata:
# labels:
# kubevirt.io/domain: strongswan
# spec:
# domain:
# cpu:
# cores: 2
# resources:
# requests:
# memory: 2Gi
# cpu: 1
# limits:
# memory: 2Gi
# cpu: 2
# memory:
# guest: 2Gi
# devices:
# rng: {}
# networkInterfaceMultiqueue: true
# disks:
# - name: containerdisk
# disk:
# bus: virtio
# - name: cloudinitdisk
# disk:
# bus: virtio
# interfaces:
# - name: wan
# masquerade: {}
# ports:
# - port: 4500
# - port: 443
# - port: 22
# - port: 500
# - name: mgmt
# bridge: {}
# - name: lan
# bridge: {}
# networks:
# - name: wan
# pod: {}
# - name: mgmt
# multus:
# networkName: ${TENANT_NAMESPACE}/mgmt-net
# - name: lan
# multus:
# networkName: ${TENANT_NAMESPACE}/lan-net
# terminationGracePeriodSeconds: 180
# volumes:
# - name: containerdisk
# containerDisk:
# image: quay.io/containerdisks/ubuntu:22.04
# - name: cloudinitdisk
# cloudInitNoCloud:
# userData: |
# #cloud-config
# users:
# - name: testuser
# groups: [sudo]
# sudo: "ALL=(ALL) NOPASSWD:ALL"
# lock_passwd: false
# passwd: "$6$oMZf5uou7t0.oAJ1$825Te06yt7JZwHSSj4MGQMjpd87LflANQpajCwIVPASkKZdOJo4L2bAEDDuK.jtu.fsRNc9bZAsYefmoqdN8O1"
# chpasswd:
# expire: false
# ssh_pwauth: true

View file

@ -0,0 +1,30 @@
---
apiVersion: v1
kind: Service
metadata:
name: fortigate-lb
namespace: ${TENANT_NAMESPACE}
labels:
app.kubernetes.io/component: fortigate-lb
spec:
type: LoadBalancer
externalTrafficPolicy: Local
ports:
- port: 4500
name: ipsec-nat
targetPort: 4500
protocol: UDP
- port: 500
name: key-management
targetPort: 500
protocol: UDP
#- port: 22
# name: ssh
# targetPort: 22
# protocol: TCP
- port: 443
name: https
targetPort: 443
protocol: TCP
selector:
kubevirt.io/domain: fortigate-ksd

View file

@ -0,0 +1,20 @@
apiVersion: "k8s.cni.cncf.io/v1"
kind: NetworkAttachmentDefinition
metadata:
name: lan-net
namespace: ${TENANT_NAMESPACE}
spec:
config: '{
"cniVersion": "0.3.1",
"type": "bridge",
"bridge": "br-lan",
"ipam": {
"type": "static",
"addresses": [
{
"address": "172.168.100.2/24",
"gateway": "172.168.100.1"
}
]
}
}'

View file

@ -0,0 +1,20 @@
apiVersion: "k8s.cni.cncf.io/v1"
kind: NetworkAttachmentDefinition
metadata:
name: mgmt-net
namespace: ${TENANT_NAMESPACE}
spec:
config: '{
"cniVersion": "0.3.1",
"type": "bridge",
"bridge": "br-mgmt",
"ipam": {
"type": "static",
"addresses": [
{
"address": "192.168.10.100/24",
"gateway": "192.168.10.1"
}
]
}
}'

View file

@ -0,0 +1,77 @@
apiVersion: kubevirt.io/v1
kind: VirtualMachine
metadata:
name: fortigate-ksd
namespace: ${TENANT_NAMESPACE}
spec:
dataVolumeTemplates:
- metadata:
name: fortigate-rootdisk-ksd
spec:
source:
http:
url: "https://glacier-1.kvant.cloud/ocp-virt-images/sources/fortios_7_6_3.qcow2"
#secretRef: s3-virt-credentials
storage:
resources:
requests:
storage: 30Gi
runStrategy: Always
template:
metadata:
labels:
kubevirt.io/domain: fortigate-ksd
spec:
domain:
cpu:
cores: 1
memory:
guest: 2Gi
features:
acpi: {}
smm:
enabled: true
firmware:
bootloader:
efi:
secureBoot: false
devices:
rng: {}
networkInterfaceMultiqueue: true
interfaces:
- name: wan
masquerade: {}
ports:
- port: 4500
- port: 443
- port: 22
- port: 500
- name: mgmt
bridge: {}
- name: lan
bridge: {}
disks:
- disk:
bus: sata
name: rootdisk
resources:
requests:
memory: 2Gi
cpu: 1
limits:
memory: 2Gi
cpu: 1
networks:
- name: wan
pod: {}
- name: mgmt
multus:
networkName: ${TENANT_NAMESPACE}/mgmt-net
- name: lan
multus:
networkName: ${TENANT_NAMESPACE}/lan-net
terminationGracePeriodSeconds: 180
volumes:
- name: rootdisk
dataVolume:
name: fortigate-rootdisk-ksd

View file

@ -0,0 +1,73 @@
apiVersion: kubevirt.io/v1
kind: VirtualMachine
metadata:
name: strongswan
namespace: ${TENANT_NAMESPACE}
spec:
running: true
template:
metadata:
labels:
kubevirt.io/domain: strongswan
spec:
domain:
cpu:
cores: 2
resources:
requests:
memory: 2Gi
cpu: 1
limits:
memory: 2Gi
cpu: 2
memory:
guest: 2Gi
devices:
rng: {}
networkInterfaceMultiqueue: true
disks:
- name: containerdisk
disk:
bus: virtio
- name: cloudinitdisk
disk:
bus: virtio
interfaces:
- name: wan
masquerade: {}
ports:
- port: 4500
- port: 443
- port: 22
- port: 500
- name: mgmt
bridge: {}
- name: lan
bridge: {}
networks:
- name: wan
pod: {}
- name: mgmt
multus:
networkName: ${TENANT_NAMESPACE}/mgmt-net
- name: lan
multus:
networkName: ${TENANT_NAMESPACE}/lan-net
terminationGracePeriodSeconds: 180
volumes:
- name: containerdisk
containerDisk:
image: quay.io/containerdisks/ubuntu:24.04
- name: cloudinitdisk
cloudInitNoCloud:
userData: |
#cloud-config
users:
- name: testuser
groups: [sudo]
sudo: "ALL=(ALL) NOPASSWD:ALL"
lock_passwd: false
passwd: "$6$oMZf5uou7t0.oAJ1$825Te06yt7JZwHSSj4MGQMjpd87LflANQpajCwIVPASkKZdOJo4L2bAEDDuK.jtu.fsRNc9bZAsYefmoqdN8O1"
chpasswd:
expire: false
ssh_pwauth: true

View file

@ -3,6 +3,14 @@ kind: Kustomization
resources:
- vars/ks.yaml
- repos/ks.yaml
- network/ks-lb.yaml
- firewall/ks-vm.yaml
- firewall-dev/ks-vm.yaml
- firewall-s3/ks-vm.yaml
- windows-vm-standard/ks-vm.yaml
- windows-vm-standard/ks-pvc.yaml
- windows-vm-standard-dev/ks-vm.yaml
- windows-vm-standard-dev/ks-pvc.yaml
- ubuntu-vm-1/ks.yaml
- ubuntu-vm-2/ks.yaml
- container/ks-debug.yaml

18
network/ks-lb.yaml Normal file
View file

@ -0,0 +1,18 @@
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
metadata:
name: &app lb
namespace: ${TENANT_NAMESPACE}
spec:
commonMetadata:
labels:
app.kubernetes.io/name: *app
path: ./network/loadbalancers
prune: true
sourceRef:
kind: GitRepository
name: tenant-repos
wait: false
interval: 30m
retryInterval: 1m
timeout: 5m

View file

@ -0,0 +1,29 @@
---
apiVersion: v1
kind: Service
metadata:
name: fortigate-lb
namespace: ${TENANT_NAMESPACE}
labels:
app.kubernetes.io/component: fortigate-lb
spec:
type: LoadBalancer
ports:
- port: 4500
name: ipsec-nat
targetPort: 4500
protocol: UDP
- port: 500
name: key-management
targetPort: 500
protocol: UDP
- port: 22
name: ssh
targetPort: 22
protocol: TCP
- port: 443
name: https
targetPort: 443
protocol: TCP
selector:
kubevirt.io/domain: fortigate-s3

View file

@ -0,0 +1,29 @@
---
apiVersion: v1
kind: Service
metadata:
name: windows-lb
namespace: ${TENANT_NAMESPACE}
labels:
app.kubernetes.io/component: windows-lb
spec:
type: LoadBalancer
ports:
- port: 8080
name: http
targetPort: 8080
protocol: TCP
- port: 443
name: https
targetPort: 443
protocol: TCP
- port: 65022
name: ssh
targetPort: 22
protocol: TCP
- port: 3389
name: rdp
targetPort: 3389
protocol: TCP
selector:
kubevirt.io/domain: windows-vm-standard

View file

@ -17,11 +17,10 @@ spec:
values:
service:
type: ClusterIP
ports:
http: 8080
ingress:
enabled: true
hostname: nginx.${TENANT_DOMAIN}.apps.ai-2.kvant.cloud
hostname: nginx.${TENANT_DOMAIN}
ingressClassName: external
extraVolumes:
- name: ${TENANT_NAMESPACE}-image-storage
persistentVolumeClaim:

View file

@ -77,7 +77,7 @@ objects:
spec:
source:
http:
url: http://nginx.demo.svc.cluster.local:8080/win2022.qcow2
url: http://nginx.demo.svc.cluster.local:8080/windows-server-2022-uefi-ns.qcow2
pvc:
accessModes:
- ReadWriteOnce

View file

@ -38,11 +38,13 @@ spec:
cloudInitNoCloud:
userData: |
#cloud-config
hostname: ubuntu-vm-1
ssh_pwauth: True
users:
- name: ubuntu
ssh-authorized-keys:
- ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPqlhZW/pPLK8zENt3o6tgl0QVinhGAF1sHvajqq3UvI ubuntu
sudo: ['ALL=(ALL) NOPASSWD:ALL']
shell: /bin/bash
- name: testuser
groups: [sudo]
sudo: "ALL=(ALL) NOPASSWD:ALL"
lock_passwd: false
passwd: "$6$oMZf5uou7t0.oAJ1$825Te06yt7JZwHSSj4MGQMjpd87LflANQpajCwIVPASkKZdOJo4L2bAEDDuK.jtu.fsRNc9bZAsYefmoqdN8O1"
chpasswd:
expire: false
ssh_pwauth: true

9
vars/demo/s3-secret.yaml Normal file
View file

@ -0,0 +1,9 @@
apiVersion: v1
kind: Secret
metadata:
name: s3-virt-credentials
namespace: ${TENANT_NAMESPACE}
type: Opaque
data:
accessKeyId: WWozQTdUdHgzbjNOa3NsS2VodzM=
secretKey: SUZJRWtSbnJnWDRPcnlNWmtSSjlheG41UlpnSTZhMjBvVW82Tm1lRA==

View file

@ -0,0 +1,18 @@
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
metadata:
name: &app windows-pvc-dev
namespace: ${TENANT_NAMESPACE}
spec:
commonMetadata:
labels:
app.kubernetes.io/name: *app
path: ./windows-vm-standard-dev/pvc
prune: true
sourceRef:
kind: GitRepository
name: tenant-repos
wait: false
interval: 30m
retryInterval: 1m
timeout: 5m

View file

@ -0,0 +1,18 @@
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
metadata:
name: &app windows-vm-standard-dev
namespace: ${TENANT_NAMESPACE}
spec:
commonMetadata:
labels:
app.kubernetes.io/name: *app
path: ./windows-vm-standard-dev/vm
prune: true
sourceRef:
kind: GitRepository
name: tenant-repos
wait: false
interval: 30m
retryInterval: 1m
timeout: 5m

View file

@ -0,0 +1,12 @@
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: windows-vm-datadisk-dev
spec:
storageClassName: ibm-spectrum-scale-fileset
volumeMode: Filesystem
accessModes:
- ReadWriteMany
resources:
requests:
storage: 200Gi

View file

@ -0,0 +1,83 @@
apiVersion: kubevirt.io/v1
kind: VirtualMachine
metadata:
name: windows-vm-standard-dev
namespace: ${TENANT_NAMESPACE}
spec:
dataVolumeTemplates:
- metadata:
name: windows-rootdisk-dev
spec:
source:
http:
url: http://nginx.demo.svc.cluster.local:8080/windows-server-2022-uefi-ns.qcow2
storage:
resources:
requests:
storage: 80Gi
sourceRef:
kind: DataSource
name: win2k22
namespace: kubevirt-os-images
runStrategy: Always
template:
metadata:
labels:
kubevirt.io/domain: windows-vm-standard-dev
spec:
domain:
cpu:
cores: 4
memory:
guest: 8Gi
features:
acpi: {}
smm:
enabled: true
firmware:
bootloader:
efi:
secureBoot: true
devices:
rng: {}
networkInterfaceMultiqueue: true
interfaces:
- name: default
masquerade: {}
ports:
- port: 8080
- port: 443
- port: 22
- port: 3389
disks:
- disk:
bus: sata
name: rootdisk-dev
- disk:
bus: sata
name: datadisk-dev
# - disk:
# bus: scsi
# name: cloudinitdisk
resources:
requests:
memory: 8Gi
cpu: 4
limits:
memory: 8Gi
cpu: 4
networks:
- name: default
pod: {}
terminationGracePeriodSeconds: 180
volumes:
- name: rootdisk-dev
dataVolume:
name: windows-rootdisk-dev
- name: datadisk-dev
persistentVolumeClaim:
claimName: windows-vm-datadisk-dev
#- name: cloudinitdisk
# cloudInitNoCloud:
# secretRef:
# name: windows-cloud-init

View file

@ -0,0 +1,18 @@
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
metadata:
name: &app windows-pvc
namespace: ${TENANT_NAMESPACE}
spec:
commonMetadata:
labels:
app.kubernetes.io/name: *app
path: ./windows-vm-standard/pvc
prune: true
sourceRef:
kind: GitRepository
name: tenant-repos
wait: false
interval: 30m
retryInterval: 1m
timeout: 5m

View file

@ -0,0 +1,18 @@
apiVersion: kustomize.toolkit.fluxcd.io/v1
kind: Kustomization
metadata:
name: &app windows-vm-standard
namespace: ${TENANT_NAMESPACE}
spec:
commonMetadata:
labels:
app.kubernetes.io/name: *app
path: ./windows-vm-standard/vm
prune: true
sourceRef:
kind: GitRepository
name: tenant-repos
wait: false
interval: 30m
retryInterval: 1m
timeout: 5m

View file

@ -0,0 +1,12 @@
apiVersion: v1
kind: PersistentVolumeClaim
metadata:
name: windows-vm-datadisk
spec:
storageClassName: ibm-spectrum-scale-fileset
volumeMode: Filesystem
accessModes:
- ReadWriteMany
resources:
requests:
storage: 200Gi

View file

@ -0,0 +1,82 @@
apiVersion: kubevirt.io/v1
kind: VirtualMachine
metadata:
name: windows-vm-standard
namespace: ${TENANT_NAMESPACE}
spec:
dataVolumeTemplates:
- metadata:
name: windows-rootdisk
spec:
source:
http:
url: http://nginx.demo.svc.cluster.local:8080/windows-server-2022-uefi-ns.qcow2
storage:
resources:
requests:
storage: 80Gi
sourceRef:
kind: DataSource
name: win2k22
namespace: kubevirt-os-images
runStrategy: Always
template:
metadata:
labels:
kubevirt.io/domain: windows-vm-standard
spec:
domain:
cpu:
cores: 4
memory:
guest: 8Gi
features:
acpi: {}
smm:
enabled: true
firmware:
bootloader:
efi: {}
devices:
rng: {}
networkInterfaceMultiqueue: true
interfaces:
- name: default
masquerade: {}
ports:
- port: 8080
- port: 443
- port: 22
- port: 3389
disks:
- disk:
bus: sata
name: rootdisk
- disk:
bus: sata
name: datadisk
# - disk:
# bus: scsi
# name: cloudinitdisk
resources:
requests:
memory: 8Gi
cpu: 4
limits:
memory: 8Gi
cpu: 4
networks:
- name: default
pod: {}
terminationGracePeriodSeconds: 180
volumes:
- name: rootdisk
dataVolume:
name: windows-rootdisk
- name: datadisk
persistentVolumeClaim:
claimName: windows-vm-datadisk
#- name: cloudinitdisk
# cloudInitNoCloud:
# secretRef:
# name: windows-cloud-init