changed NAD to static to test

This commit is contained in:
maximilian.bartz 2025-07-22 12:16:37 +02:00
parent f76153ff5d
commit b15d8e6882
2 changed files with 80 additions and 1 deletions

View file

@ -9,6 +9,12 @@ spec:
"type": "bridge",
"bridge": "br-mgmt",
"ipam": {
"type": "dhcp"
"type": "static",
"addresses": [
{
"address": "192.168.10.100/24",
"gateway": "192.168.10.1"
}
]
}
}'

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