From 77c060d65609f3d5beb2c93da8226fe91834401c Mon Sep 17 00:00:00 2001 From: fossedihelm Date: Thu, 25 Jul 2024 06:21:32 +0200 Subject: [PATCH] Remove Windows 2k12 template Signed-off-by: fossedihelm --- README.md | 1 - generate-templates.yaml | 12 -- templates/windows2k12.tpl.yaml | 196 --------------------------------- 3 files changed, 209 deletions(-) diff --git a/README.md b/README.md index ee586e01..544edb7d 100644 --- a/README.md +++ b/README.md @@ -72,7 +72,6 @@ The table below lists the guest operating systems that are covered by the templa | Guest OS | Meta-template | |---|---| -| Microsoft Windows Server 2012 R2 | [windows2k12](templates/windows2k12.tpl.yaml) | | Microsoft Windows Server 2016 | [windows2k16](templates/windows2k16.tpl.yaml) | | Microsoft Windows Server 2019 | [windows2k19](templates/windows2k19.tpl.yaml) | | Microsoft Windows Server 2022 | [windows2k22](templates/windows2k22.tpl.yaml) | diff --git a/generate-templates.yaml b/generate-templates.yaml index dd95ee26..2cb79cdb 100644 --- a/generate-templates.yaml +++ b/generate-templates.yaml @@ -313,18 +313,6 @@ containerdisk_urls: "{{ ubuntu_containerdisk_urls }}" image_urls: "{{ ubuntu_image_urls }}" - - name: Generate Windows server 2012 R2 templates - template: - src: windows2k12.tpl.yaml - dest: "{{ playbook_dir }}/dist/templates/windows2k12r2-{{ item.workload }}-{{ item.flavor }}.yaml" - with_items: - - {flavor: medium, workload: server, memsize: "4Gi", cpus: 1, iothreads: False, emulatorthread: False, multiqueue: False, tablet: True, default: True} - - {flavor: medium, workload: highperformance, memsize: "4Gi", cpus: 1, iothreads: True, emulatorthread: True, multiqueue: True, tablet: True, default: False} - - {flavor: large, workload: server, memsize: "8Gi", cpus: 2, iothreads: False, emulatorthread: False, multiqueue: False, tablet: True, default: False} - - {flavor: large, workload: highperformance, memsize: "8Gi", cpus: 2, iothreads: True, emulatorthread: True, multiqueue: True, tablet: True, default: False} - vars: - osinfoname: win2k12r2 - - name: Generate Windows server 2016 templates template: src: windows2k16.tpl.yaml diff --git a/templates/windows2k12.tpl.yaml b/templates/windows2k12.tpl.yaml index 83542f3b..e69de29b 100644 --- a/templates/windows2k12.tpl.yaml +++ b/templates/windows2k12.tpl.yaml @@ -1,196 +0,0 @@ -apiVersion: template.openshift.io/v1 -kind: Template -metadata: - name: windows2k12r2-{{ item.workload }}-{{ item.flavor }} - annotations: - template.kubevirt.io/deprecated: "true" - openshift.io/display-name: "Microsoft Windows Server 2012 R2 VM" - description: >- - Template for Microsoft Windows Server 2012 R2 VM. - A PVC with the Windows disk image must be available. - tags: "hidden,kubevirt,virtualmachine,windows" - iconClass: "icon-windows" - openshift.io/provider-display-name: "KubeVirt" - openshift.io/documentation-url: "https://github.com/kubevirt/common-templates" - openshift.io/support-url: "https://github.com/kubevirt/common-templates/issues" - template.openshift.io/bindable: "false" - template.kubevirt.io/version: v1alpha1 - defaults.template.kubevirt.io/disk: rootdisk - defaults.template.kubevirt.io/network: default - template.kubevirt.io/editable: | - /objects[0].spec.template.spec.domain.cpu.cores - /objects[0].spec.template.spec.domain.memory.guest - /objects[0].spec.template.spec.domain.devices.disks - /objects[0].spec.template.spec.volumes - /objects[0].spec.template.spec.networks - name.os.template.kubevirt.io/win2k12r2: {{ lookup('osinfo', 'win2k12r2').name }} - labels: - os.template.kubevirt.io/win2k12r2: "true" - workload.template.kubevirt.io/{{ item.workload }}: "true" - flavor.template.kubevirt.io/{{ item.flavor }}: "true" - template.kubevirt.io/type: "base" - template.kubevirt.io/version: "{{ lookup('env', 'VERSION') | default('devel', true) }}" -{% if item.default %} - template.kubevirt.io/default-os-variant: "true" -{% endif %} -objects: -- apiVersion: kubevirt.io/v1 - kind: VirtualMachine - metadata: - name: ${NAME} - labels: - vm.kubevirt.io/template: windows2k12r2-{{ item.workload }}-{{ item.flavor }} - vm.kubevirt.io/template.version: "{{ lookup('env', 'VERSION') | default('devel', true) }}" - vm.kubevirt.io/template.revision: "{{ lookup('env', 'REVISION') | default(1, true) }}" - app: ${NAME} - annotations: - vm.kubevirt.io/validations: | - [ - { - "name": "minimal-required-memory", - "path": "jsonpath::.spec.domain.memory.guest", - "rule": "integer", - "message": "This VM requires more memory.", - "min": {{ lookup('osinfo', osinfoname)["minimum_resources.0.ram"] }} - }, { - "name": "windows-virtio-bus", - "path": "jsonpath::.spec.domain.devices.disks[*].disk.bus", - "valid": "jsonpath::.spec.domain.devices.disks[*].disk.bus", - "rule": "enum", - "message": "virtio disk bus type has better performance, install virtio drivers in VM and change bus type", - "values": ["virtio"], - "justWarning": true - }, { - "name": "windows-disk-bus", - "path": "jsonpath::.spec.domain.devices.disks[*].disk.bus", - "valid": "jsonpath::.spec.domain.devices.disks[*].disk.bus", - "rule": "enum", - "message": "disk bus has to be either virtio or sata or scsi", - "values": ["virtio", "sata", "scsi"] - }, { - "name": "windows-cd-bus", - "path": "jsonpath::.spec.domain.devices.disks[*].cdrom.bus", - "valid": "jsonpath::.spec.domain.devices.disks[*].cdrom.bus", - "rule": "enum", - "message": "cd bus has to be sata", - "values": ["sata"] - } - ] - spec: - dataVolumeTemplates: - - apiVersion: cdi.kubevirt.io/v1beta1 - kind: DataVolume - metadata: - name: ${NAME} - spec: - storage: - resources: - requests: - storage: 60Gi - sourceRef: - kind: DataSource - name: ${DATA_SOURCE_NAME} - namespace: ${DATA_SOURCE_NAMESPACE} - running: false - template: - metadata: - annotations: - vm.kubevirt.io/os: "windows2k12r2" - vm.kubevirt.io/workload: "{{ item.workload }}" - vm.kubevirt.io/flavor: "{{ item.flavor }}" - labels: - kubevirt.io/domain: ${NAME} - kubevirt.io/size: {{ item.flavor }} - spec: - architecture: amd64 - domain: - clock: - utc: {} - timer: - hpet: - present: false - pit: - tickPolicy: delay - rtc: - tickPolicy: catchup - hyperv: {} - cpu: - sockets: {{ item.cpus }} - cores: 1 - threads: 1 -{% if item.iothreads or item.emulatorthread %} - dedicatedCpuPlacement: True -{% endif %} -{% if item.emulatorthread %} - isolateEmulatorThread: True -{% endif %} - memory: - guest: {{ item.memsize }} - features: - acpi: {} - apic: {} - smm: {} - hyperv: - relaxed: {} - vapic: {} - vpindex: {} - spinlocks: - spinlocks: 8191 - synic: {} - synictimer: - direct: {} - tlbflush: {} - frequencies: {} - reenlightenment: {} - ipi: {} - runtime: {} - reset: {} - firmware: - bootloader: - efi: - secureBoot: true - devices: -{% if item.multiqueue and item.cpus > 1 %} - networkInterfaceMultiqueue: True -{% endif %} - disks: - - disk: -{% if item.workload == "highperformance" %} - bus: virtio -{% else %} - bus: sata -{% endif %} - name: rootdisk - interfaces: - - masquerade: {} -{% if item.multiqueue %} - model: virtio -{% else %} - model: e1000e -{% endif %} - name: default -{% if item.tablet %} - inputs: - - type: tablet - bus: usb - name: tablet -{% endif %} - terminationGracePeriodSeconds: 3600 - volumes: - - dataVolume: - name: ${NAME} - name: rootdisk - networks: - - name: default - pod: {} -parameters: -- name: NAME - description: VM name - generate: expression - from: "windows2012-[a-z0-9]{6}" -- name: DATA_SOURCE_NAME - description: Name of the DataSource to clone - value: win2k12r2 -- name: DATA_SOURCE_NAMESPACE - description: Namespace of the DataSource - value: kubevirt-os-images