apiVersion: tekton.dev/v1beta1
kind: PipelineRun
metadata:
  annotations:
    operator-sdk/primary-resource: openshift-cnv/tto-kubevirt-hyperconverged
    operator-sdk/primary-resource-type: TektonTasks.tektontasks.kubevirt.io
    pipeline.openshift.io/started-by: 'kube:admin'
  resourceVersion: '679932'
  name: windows10-customize-m41peu
  uid: 6bd376df-2ab8-414e-aa31-70ccb294a161
  creationTimestamp: '2023-02-13T18:05:02Z'
  generation: 2
  managedFields:
    - apiVersion: tekton.dev/v1beta1
      fieldsType: FieldsV1
      fieldsV1:
        'f:metadata':
          'f:annotations':
            .: {}
            'f:operator-sdk/primary-resource': {}
            'f:operator-sdk/primary-resource-type': {}
            'f:pipeline.openshift.io/started-by': {}
          'f:labels':
            .: {}
            'f:app.kubernetes.io/component': {}
            'f:app.kubernetes.io/managed-by': {}
            'f:app.kubernetes.io/name': {}
            'f:app.kubernetes.io/part-of': {}
            'f:app.kubernetes.io/version': {}
            'f:tekton.dev/pipeline': {}
        'f:spec':
          .: {}
          'f:params': {}
          'f:pipelineRef':
            .: {}
            'f:name': {}
          'f:serviceAccountName': {}
          'f:status': {}
          'f:timeout': {}
      manager: Mozilla
      operation: Update
      time: '2023-02-13T18:06:19Z'
    - apiVersion: tekton.dev/v1beta1
      fieldsType: FieldsV1
      fieldsV1:
        'f:status':
          .: {}
          'f:completionTime': {}
          'f:conditions': {}
          'f:pipelineSpec':
            .: {}
            'f:finally': {}
            'f:params': {}
            'f:results': {}
            'f:tasks': {}
          'f:skippedTasks': {}
          'f:startTime': {}
          'f:taskRuns':
            .: {}
            'f:windows10-customize-m41peu-copy-template-customize':
              .: {}
              'f:pipelineTaskName': {}
              'f:status':
                .: {}
                'f:completionTime': {}
                'f:conditions': {}
                'f:podName': {}
                'f:startTime': {}
                'f:steps': {}
                'f:taskResults': {}
                'f:taskSpec':
                  .: {}
                  'f:params': {}
                  'f:results': {}
                  'f:steps': {}
            'f:windows10-customize-m41peu-create-vm-from-template':
              .: {}
              'f:pipelineTaskName': {}
              'f:status':
                .: {}
                'f:completionTime': {}
                'f:conditions': {}
                'f:podName': {}
                'f:startTime': {}
                'f:steps': {}
                'f:taskResults': {}
                'f:taskSpec':
                  .: {}
                  'f:params': {}
                  'f:results': {}
                  'f:steps': {}
            'f:windows10-customize-m41peu-modify-vm-template-customize':
              .: {}
              'f:pipelineTaskName': {}
              'f:status':
                .: {}
                'f:completionTime': {}
                'f:conditions': {}
                'f:podName': {}
                'f:startTime': {}
                'f:steps': {}
                'f:taskResults': {}
                'f:taskSpec':
                  .: {}
                  'f:params': {}
                  'f:results': {}
                  'f:steps': {}
            'f:windows10-customize-m41peu-wait-for-vmi-status':
              .: {}
              'f:pipelineTaskName': {}
              'f:status':
                .: {}
                'f:completionTime': {}
                'f:conditions': {}
                'f:podName': {}
                'f:startTime': {}
                'f:steps': {}
                'f:taskSpec':
                  .: {}
                  'f:params': {}
                  'f:steps': {}
      manager: openshift-pipelines-controller
      operation: Update
      subresource: status
      time: '2023-02-13T19:05:02Z'
  namespace: openshift-cnv
  labels:
    app.kubernetes.io/component: tektonPipelines
    app.kubernetes.io/managed-by: tekton-tasks-operator
    app.kubernetes.io/name: tekton-pipelines
    app.kubernetes.io/part-of: hyperconverged-cluster
    app.kubernetes.io/version: 4.12.1
    tekton.dev/pipeline: windows10-customize
spec:
  params:
    - name: sourceTemplateName
      value: windows10-desktop-medium
    - name: sourceTemplateNamespace
      value: openshift
    - name: customizeConfigMapName
      value: windows10-sqlserver
    - name: customizeTemplateName
      value: windows10-desktop-medium-customize-sqlserver
    - name: allowReplaceCustomizationTemplate
      value: 'false'
    - name: goldenTemplateName
      value: windows10-desktop-medium-golden-sqlserver
    - name: allowReplaceGoldenTemplate
      value: 'false'
  pipelineRef:
    name: windows10-customize
  serviceAccountName: pipeline
  status: StoppedRunFinally
  timeout: 1h0m0s
status:
  completionTime: '2023-02-13T19:05:02Z'
  conditions:
    - lastTransitionTime: '2023-02-13T19:05:02Z'
      message: >-
        invalid pipelineresults [baseDvName baseDvNamespace goldenTemplateName
        goldenTemplateNamespace], the referred results don't exist
      reason: PipelineValidationFailed
      status: 'False'
      type: Succeeded
  pipelineSpec:
    finally:
      - name: cleanup-vm
        params:
          - name: vmName
            value: $(tasks.create-vm-from-template.results.name)
          - name: delete
            value: 'true'
        taskRef:
          kind: ClusterTask
          name: cleanup-vm
        timeout: 10m0s
      - name: delete-template-customize
        params:
          - name: templateName
            value: windows10-desktop-medium-customize-sqlserver
          - name: templateNamespace
            value: $(tasks.copy-template-customize.results.namespace)
          - name: deleteTemplate
            value: 'true'
        taskRef:
          kind: ClusterTask
          name: modify-vm-template
    params:
      - default: windows10-desktop-large
        description: >-
          Name of the Template which is used to customize Windows 10 and create
          a golden Template. The default boot source of this template needs to
          be available.
        name: sourceTemplateName
        type: string
      - default: openshift
        description: >-
          Namespace of the Template which is used to customize Windows 10 and
          create a golden Template. The default boot source of this template
          needs to be available.
        name: sourceTemplateNamespace
        type: string
      - default: windows10-sqlserver
        description: >-
          Name of the ConfigMap containing the customization and sysprep
          configuration files (unattend.xml, etc.).
        name: customizeConfigMapName
        type: string
      - default: windows10-desktop-large-customize-sqlserver
        description: >-
          Name of the customize Template which is created. A VM created from
          this template is used to customize Windows 10.
        name: customizeTemplateName
        type: string
      - default: 'false'
        description: Allow to replace an already existing customize Template.
        name: allowReplaceCustomizationTemplate
        type: string
      - default: windows10-desktop-large-golden-sqlserver
        description: >-
          Name of the golden Template which is created. Pre-installed Windows
          VMs can be created from this template.
        name: goldenTemplateName
        type: string
      - default: 'false'
        description: Allow to replace an already existing golden Template.
        name: allowReplaceGoldenTemplate
        type: string
    results:
      - description: Name of the created base DataVolume
        name: baseDvName
        value: $(tasks.create-base-dv.results.name)
      - description: Namespace of the created base DataVolume
        name: baseDvNamespace
        value: $(tasks.create-base-dv.results.namespace)
      - description: Name of the created golden Template
        name: goldenTemplateName
        value: $(tasks.copy-template-golden.results.name)
      - description: Namespace of the created golden Template
        name: goldenTemplateNamespace
        value: $(tasks.copy-template-golden.results.namespace)
    tasks:
      - name: copy-template-customize
        params:
          - name: sourceTemplateName
            value: windows10-desktop-medium
          - name: sourceTemplateNamespace
            value: openshift
          - name: targetTemplateName
            value: windows10-desktop-medium-customize-sqlserver
          - name: allowReplace
            value: 'false'
        taskRef:
          kind: ClusterTask
          name: copy-template
        timeout: 10m0s
      - name: modify-vm-template-customize
        params:
          - name: templateName
            value: $(tasks.copy-template-customize.results.name)
          - name: templateAnnotations
            value:
              - 'openshift.io/display-name: Microsoft Windows 10 Customize VM'
              - 'description: Template for customizing Microsoft Windows 10.'
          - name: deleteDatavolumeTemplate
            value: 'true'
          - name: datavolumeTemplates
            value:
              - |
                {
                  "apiVersion": "cdi.kubevirt.io/v1beta1",
                  "kind": "DataVolume",
                  "metadata": {
                      "name": "${NAME}"
                  },
                  "spec": {
                    "storage": {},
                    "sourceRef": {
                      "kind": "DataSource",
                      "name": "${DATA_SOURCE_NAME}",
                      "namespace": "${DATA_SOURCE_NAMESPACE}"
                    }
                  }
                }
          - name: disks
            value:
              - '{"name": "rootdisk", "disk": {"bus": "virtio"}}'
              - '{"name": "sysprep", "cdrom": {"bus": "sata"}}'
          - name: volumes
            value:
              - '{"name": "rootdisk", "dataVolume": {"name": "${NAME}"}}'
              - >-
                {"name": "sysprep", "sysprep": {"configMap": {"name":
                "windows10-sqlserver"}}}
        runAfter:
          - copy-template-customize
        taskRef:
          kind: ClusterTask
          name: modify-vm-template
        timeout: 10m0s
      - name: create-vm-from-template
        params:
          - name: templateName
            value: $(tasks.modify-vm-template-customize.results.name)
          - name: runStrategy
            value: RerunOnFailure
          - name: startVM
            value: 'true'
        runAfter:
          - modify-vm-template-customize
        taskRef:
          kind: ClusterTask
          name: create-vm-from-template
        timeout: 10m0s
      - name: wait-for-vmi-status
        params:
          - name: vmiName
            value: $(tasks.create-vm-from-template.results.name)
          - name: successCondition
            value: status.phase == Succeeded
          - name: failureCondition
            value: 'status.phase in (Failed, Unknown)'
        runAfter:
          - create-vm-from-template
        taskRef:
          kind: ClusterTask
          name: wait-for-vmi-status
        timeout: 2h0m0s
      - name: create-base-dv
        params:
          - name: manifest
            value: |
              apiVersion: cdi.kubevirt.io/v1beta1
              kind: DataVolume
              metadata:
                generateName: windows10-base-
                annotations:
                  cdi.kubevirt.io/storage.bind.immediate.requested: \"true\"
                  cdi.kubevirt.io/storage.deleteAfterCompletion: "false"
              spec:
                storage:
                  resources:
                    requests:
                      storage: 20Gi
                source:
                  pvc:
                    name: $(tasks.create-vm-from-template.results.name)
                    namespace: $(tasks.create-vm-from-template.results.namespace)
          - name: waitForSuccess
            value: 'true'
        runAfter:
          - wait-for-vmi-status
        taskRef:
          kind: ClusterTask
          name: modify-data-object
        timeout: 1h0m0s
      - name: copy-template-golden
        params:
          - name: sourceTemplateName
            value: windows10-desktop-medium
          - name: sourceTemplateNamespace
            value: openshift
          - name: targetTemplateName
            value: windows10-desktop-medium-golden-sqlserver
          - name: allowReplace
            value: 'false'
        runAfter:
          - create-base-dv
        taskRef:
          kind: ClusterTask
          name: copy-template
        timeout: 10m0s
      - name: modify-vm-template-golden
        params:
          - name: templateName
            value: $(tasks.copy-template-golden.results.name)
          - name: templateAnnotations
            value:
              - >-
                openshift.io/display-name: Microsoft Windows 10 Customized VM
                Golden
              - >-
                description: Template for creating customized Microsoft Windows
                10 VMs.
          - name: deleteDatavolumeTemplate
            value: 'true'
          - name: datavolumeTemplates
            value:
              - |
                {
                  "apiVersion": "cdi.kubevirt.io/v1beta1",
                  "kind": "DataVolume",
                  "metadata": {
                      "name": "${NAME}"
                  },
                  "spec": {
                    "storage": {
                      "resources": {
                        "requests": {
                          "storage": "60Gi"
                        }
                      }
                    },
                    "source": {
                      "pvc": {
                        "name": "$(tasks.create-base-dv.results.name)",
                        "namespace": "$(tasks.create-base-dv.results.namespace)"
                      }
                    }
                  }
                }
          - name: deleteDisks
            value: 'true'
          - name: disks
            value:
              - '{"name": "rootdisk", "disk": {"bus": "virtio"}}'
          - name: deleteVolumes
            value: 'true'
          - name: volumes
            value:
              - '{"name": "rootdisk", "dataVolume": {"name": "${NAME}"}}'
          - name: deleteTemplateParameters
            value: 'true'
          - name: templateParameters
            value:
              - >-
                {"name": "NAME", "description": "VM name", "generate":
                "expression", "from": "windows-[a-z0-9]{6}"}
        runAfter:
          - copy-template-golden
        taskRef:
          kind: ClusterTask
          name: modify-vm-template
        timeout: 10m0s
  skippedTasks:
    - name: create-base-dv
      reason: PipelineRun was gracefully stopped
    - name: copy-template-golden
      reason: PipelineRun was gracefully stopped
    - name: modify-vm-template-golden
      reason: PipelineRun was gracefully stopped
  startTime: '2023-02-13T18:05:02Z'
  taskRuns:
    windows10-customize-m41peu-copy-template-customize:
      pipelineTaskName: copy-template-customize
      status:
        completionTime: '2023-02-13T18:05:08Z'
        conditions:
          - lastTransitionTime: '2023-02-13T18:05:08Z'
            message: All Steps have completed executing
            reason: Succeeded
            status: 'True'
            type: Succeeded
        podName: windows10-customize-m41peu-copy-template-customize-pod
        startTime: '2023-02-13T18:05:02Z'
        steps:
          - container: step-copytemplate
            imageID: >-
              registry.redhat.io/container-native-virtualization/kubevirt-tekton-tasks-copy-template@sha256:9362b0b97c0ac67f9ce868510bae680032ccda9b3dc65886d649d5e30ab1b730
            name: copytemplate
            terminated:
              containerID: >-
                cri-o://18e0e190683496f3a01fdd83da98d52b2df83a6ea5a79407230298ab98b79b46
              exitCode: 0
              finishedAt: '2023-02-13T18:05:07Z'
              message: >-
                [{"key":"name","value":"windows10-desktop-medium-customize-sqlserver","type":1},{"key":"namespace","value":"openshift-cnv","type":1}]
              reason: Completed
              startedAt: '2023-02-13T18:05:07Z'
        taskResults:
          - name: name
            type: string
            value: windows10-desktop-medium-customize-sqlserver
          - name: namespace
            type: string
            value: openshift-cnv
        taskSpec:
          params:
            - description: Name of an OpenShift template to copy template from.
              name: sourceTemplateName
              type: string
            - default: ''
              description: >-
                Namespace of an source OpenShift template to copy template from.
                (defaults to active namespace)
              name: sourceTemplateNamespace
              type: string
            - default: ''
              description: Name of an target OpenShift template.
              name: targetTemplateName
              type: string
            - default: ''
              description: >-
                Namespace of an target OpenShift template to create in.
                (defaults to active namespace)
              name: targetTemplateNamespace
              type: string
            - default: 'false'
              description: >-
                Allow replacing already existing template (same combination
                name/namespace). Allowed values true/false
              name: allowReplace
              type: string
          results:
            - description: The name of a template that was created.
              name: name
              type: string
            - description: The namespace of a template that was created.
              name: namespace
              type: string
          steps:
            - args:
                - '--output=yaml'
              command:
                - copy-template
              env:
                - name: SOURCE_TEMPLATE_NAME
                  value: windows10-desktop-medium
                - name: SOURCE_TEMPLATE_NAMESPACE
                  value: openshift
                - name: TARGET_TEMPLATE_NAME
                  value: windows10-desktop-medium-customize-sqlserver
                - name: TARGET_TEMPLATE_NAMESPACE
                - name: ALLOW_REPLACE
                  value: 'false'
              image: >-
                registry.redhat.io/container-native-virtualization/kubevirt-tekton-tasks-copy-template@sha256:dafeb0f59840d0b1d4d61d5228d5805271bb4a1c081cb0cc008ec6b84d906536
              name: copytemplate
              resources: {}
    windows10-customize-m41peu-create-vm-from-template:
      pipelineTaskName: create-vm-from-template
      status:
        completionTime: '2023-02-13T18:05:18Z'
        conditions:
          - lastTransitionTime: '2023-02-13T18:05:18Z'
            message: All Steps have completed executing
            reason: Succeeded
            status: 'True'
            type: Succeeded
        podName: windows10-customize-m41peu-create-vm-from-template-pod
        startTime: '2023-02-13T18:05:13Z'
        steps:
          - container: step-createvm
            imageID: >-
              registry.redhat.io/container-native-virtualization/kubevirt-tekton-tasks-create-vm-from-template@sha256:9700758f67b71eb0ba82d87d0682907ea10a4d26251916bb50f79d1bf68c76ae
            name: createvm
            terminated:
              containerID: >-
                cri-o://7b6611f88fd2d49c28227ce396e02a67aca9a741d5dc8465b2272956f055df56
              exitCode: 0
              finishedAt: '2023-02-13T18:05:18Z'
              message: >-
                [{"key":"name","value":"windows-4liy4a","type":1},{"key":"namespace","value":"openshift-cnv","type":1}]
              reason: Completed
              startedAt: '2023-02-13T18:05:18Z'
        taskResults:
          - name: name
            type: string
            value: windows-4liy4a
          - name: namespace
            type: string
            value: openshift-cnv
        taskSpec:
          params:
            - description: Name of an OKD template to create VM from.
              name: templateName
              type: string
            - default: ''
              description: >-
                Namespace of an OKD template to create VM from. (defaults to
                active namespace)
              name: templateNamespace
              type: string
            - default: []
              description: >-
                Template params to pass when processing the template manifest.
                Each param should have KEY:VAL format. Eg ["NAME:my-vm",
                "DESC:blue"]
              name: templateParams
              type: array
            - default: ''
              description: Namespace where to create the VM. (defaults to active namespace)
              name: vmNamespace
              type: string
            - default: ''
              description: >-
                Set to true or false to start / not start vm after creation. In
                case of runStrategy is set to Always, startVM flag is ignored.
              name: startVM
              type: string
            - default: ''
              description: >-
                Set runStrategy to VM. If runStrategy is set, vm.spec.running
                attribute is set to nil.
              name: runStrategy
              type: string
            - default: []
              description: >-
                Add DVs to VM Volumes. Replaces a particular volume if in
                VOLUME_NAME:DV_NAME format. Eg. ["rootdisk:my-dv", "my-dv2"]
              name: dataVolumes
              type: array
            - default: []
              description: >-
                Add DVs to VM Volumes and add VM to DV ownerReferences. These
                DataVolumes will be deleted once the created VM gets deleted.
                Replaces a particular volume if in VOLUME_NAME:DV_NAME format.
                Eg. ["rootdisk:my-dv", "my-dv2"]
              name: ownDataVolumes
              type: array
            - default: []
              description: >-
                Add PVCs to VM Volumes. Replaces a particular volume if in
                VOLUME_NAME:PVC_NAME format. Eg. ["rootdisk:my-pvc", "my-pvc2"]
              name: persistentVolumeClaims
              type: array
            - default: []
              description: >-
                Add PVCs to VM Volumes and add VM to PVC ownerReferences. These
                PVCs will be deleted once the created VM gets deleted. Replaces
                a particular volume if in VOLUME_NAME:PVC_NAME format. Eg.
                ["rootdisk:my-pvc", "my-pvc2"]
              name: ownPersistentVolumeClaims
              type: array
          results:
            - description: The name of a VM that was created.
              name: name
              type: string
            - description: The namespace of a VM that was created.
              name: namespace
              type: string
          steps:
            - args:
                - '--output=yaml'
                - '--dvs'
                - '--own-dvs'
                - '--pvcs'
                - '--own-pvcs'
                - '--template-params'
              command:
                - create-vm
              env:
                - name: TEMPLATE_NAME
                  value: windows10-desktop-medium-customize-sqlserver
                - name: TEMPLATE_NAMESPACE
                - name: VM_NAMESPACE
                - name: START_VM
                  value: 'true'
                - name: RUN_STRATEGY
                  value: RerunOnFailure
              image: >-
                registry.redhat.io/container-native-virtualization/kubevirt-tekton-tasks-create-vm-from-template@sha256:ceb8ef36441f220cdd1dc55f57031c172bfa2eeaa1c5d586f7fa415523d8a4ed
              name: createvm
              resources: {}
    windows10-customize-m41peu-modify-vm-template-customize:
      pipelineTaskName: modify-vm-template-customize
      status:
        completionTime: '2023-02-13T18:05:13Z'
        conditions:
          - lastTransitionTime: '2023-02-13T18:05:13Z'
            message: All Steps have completed executing
            reason: Succeeded
            status: 'True'
            type: Succeeded
        podName: windows10-customize-m41peu-modify-vm-template-customize-pod
        startTime: '2023-02-13T18:05:08Z'
        steps:
          - container: step-modifyvmtemplate
            imageID: >-
              registry.redhat.io/container-native-virtualization/kubevirt-tekton-tasks-modify-vm-template@sha256:341e77255430d9ac1b7dfef1cacd4524802901e6cf16bc30b4b2f11e6756de23
            name: modifyvmtemplate
            terminated:
              containerID: >-
                cri-o://095178aadccb774ae48a4bc0441f420a520ac12256681c2459d8952e8e8b5af1
              exitCode: 0
              finishedAt: '2023-02-13T18:05:12Z'
              message: >-
                [{"key":"name","value":"windows10-desktop-medium-customize-sqlserver","type":1},{"key":"namespace","value":"openshift-cnv","type":1}]
              reason: Completed
              startedAt: '2023-02-13T18:05:12Z'
        taskResults:
          - name: name
            type: string
            value: windows10-desktop-medium-customize-sqlserver
          - name: namespace
            type: string
            value: openshift-cnv
        taskSpec:
          params:
            - description: Name of an OpenShift template.
              name: templateName
              type: string
            - default: ''
              description: >-
                Namespace of an source OpenShift template. (defaults to active
                namespace)
              name: templateNamespace
              type: string
            - default: '0'
              description: Number of CPU sockets
              name: cpuSockets
              type: string
            - default: '0'
              description: Number of CPU cores
              name: cpuCores
              type: string
            - default: '0'
              description: Number of CPU threads
              name: cpuThreads
              type: string
            - default: ''
              description: Number of memory vm can use
              name: memory
              type: string
            - default: []
              description: >-
                Template labels. If template contains same label, it will be
                replaced. Each param should have KEY:VAL format. Eg
                ["key:value", "key:value"].
              name: templateLabels
              type: array
            - default: []
              description: >-
                Template Annotations. If template contains same annotation, it
                will be replaced. Each param should have KEY:VAL format. Eg
                ["key:value", "key:value"]
              name: templateAnnotations
              type: array
            - default: []
              description: >-
                VM labels. If VM contains same label, it will be replaced. Each
                param should have KEY:VAL format. Eg ["key:value", "key:value"].
              name: vmLabels
              type: array
            - default: []
              description: >-
                VM annotations. If VM contains same annotation, it will be
                replaced. Each param should have KEY:VAL format. Eg
                ["key:value", "key:value"].
              name: vmAnnotations
              type: array
            - default: []
              description: >-
                VM disks in json format, replace vm disk if same name, otherwise
                new disk is appended. Eg [{"name": "test", "cdrom": {"bus":
                "sata"}}, {"name": "disk2"}]
              name: disks
              type: array
            - default: 'false'
              description: >-
                Set to "true" or "false" if task should delete VM disks. New
                disks (from disks parameter) are applied, after old disks are
                deleted.
              name: deleteDisks
              type: string
            - default: []
              description: >-
                VM volumes in json format, replace vm volume if same name,
                otherwise new volume is appended. Eg [{"name":
                "virtiocontainerdisk", "containerDisk": {"image":
                "kubevirt/virtio-container-disk"}}]
              name: volumes
              type: array
            - default: []
              description: >-
                Datavolume templates in json format, replace datavolume if same
                name, otherwise new datavolume is appended. If
                deleteDatavolumeTemplate is set, first datavolumes are deleted
                and then datavolumes from this attribute are added. Eg
                [{"apiVersion": "cdi.kubevirt.io/v1beta1", "kind": "DataVolume",
                "metadata":{"name": "test1"}, "spec": {"source": {"http":
                {"url": "test.somenonexisting"}}}}]
              name: datavolumeTemplates
              type: array
            - default: 'false'
              description: >-
                Set to "true" or "false" if task should delete datavolume
                template in template and all associated volumes and disks.
              name: deleteDatavolumeTemplate
              type: string
            - default: 'false'
              description: >-
                Set to "true" or "false" if task should delete VM volumes. New
                volumes (from volumes parameter) are applied, after old volumes
                are deleted.
              name: deleteVolumes
              type: string
            - default: []
              description: >-
                Definition of template parameters. Eg [{"description": "VM
                name", "name": "NAME"}]
              name: templateParameters
              type: array
            - default: 'false'
              description: >-
                Set to "true" or "false" if task should delete template
                parameters. New parameters (from templateParameters parameter)
                are applied, after old parameters are deleted.
              name: deleteTemplateParameters
              type: string
            - default: 'false'
              description: >-
                Set to `true` or `false` if task should delete the specified
                template. If set to 'true' the template will be deleted and all
                other parameters are ignored.
              name: deleteTemplate
              type: string
          results:
            - description: The name of a template that was updated.
              name: name
              type: string
            - description: The namespace of a template that was updated.
              name: namespace
              type: string
          steps:
            - args:
                - '--output=yaml'
                - '--template-labels'
                - '--template-annotations'
                - 'openshift.io/display-name: Microsoft Windows 10 Customize VM'
                - 'description: Template for customizing Microsoft Windows 10.'
                - '--vm-labels'
                - '--vm-annotations'
                - '--disks'
                - '{"name": "rootdisk", "disk": {"bus": "virtio"}}'
                - '{"name": "sysprep", "cdrom": {"bus": "sata"}}'
                - '--volumes'
                - '{"name": "rootdisk", "dataVolume": {"name": "${NAME}"}}'
                - >-
                  {"name": "sysprep", "sysprep": {"configMap": {"name":
                  "windows10-sqlserver"}}}
                - '--datavolumeTemplates'
                - |
                  {
                    "apiVersion": "cdi.kubevirt.io/v1beta1",
                    "kind": "DataVolume",
                    "metadata": {
                        "name": "${NAME}"
                    },
                    "spec": {
                      "storage": {},
                      "sourceRef": {
                        "kind": "DataSource",
                        "name": "${DATA_SOURCE_NAME}",
                        "namespace": "${DATA_SOURCE_NAMESPACE}"
                      }
                    }
                  }
                - '--templateParameters'
              command:
                - modify-vm-template
              env:
                - name: TEMPLATE_NAME
                  value: windows10-desktop-medium-customize-sqlserver
                - name: TEMPLATE_NAMESPACE
                - name: CPU_SOCKETS
                  value: '0'
                - name: CPU_CORES
                  value: '0'
                - name: CPU_THREADS
                  value: '0'
                - name: MEMORY
                - name: DELETE_DATAVOLUME_TEMPLATE
                  value: 'true'
                - name: DELETE_DISKS
                  value: 'false'
                - name: DELETE_VOLUMES
                  value: 'false'
                - name: DELETE_TEMPLATE_PARAMETERS
                  value: 'false'
                - name: DELETE_TEMPLATE
                  value: 'false'
              image: >-
                registry.redhat.io/container-native-virtualization/kubevirt-tekton-tasks-modify-vm-template@sha256:f57187beff4063bc46765fc56669eb3d3672d4f5b66f727f4cab922a2ccdea30
              name: modifyvmtemplate
              resources: {}
    windows10-customize-m41peu-wait-for-vmi-status:
      pipelineTaskName: wait-for-vmi-status
      status:
        completionTime: '2023-02-13T19:05:02Z'
        conditions:
          - lastTransitionTime: '2023-02-13T19:05:02Z'
            message: >-
              TaskRun "windows10-customize-m41peu-wait-for-vmi-status" was
              cancelled. TaskRun cancelled as the PipelineRun it belongs to has
              timed out.
            reason: TaskRunCancelled
            status: 'False'
            type: Succeeded
        podName: windows10-customize-m41peu-wait-for-vmi-status-pod
        startTime: '2023-02-13T18:05:18Z'
        steps:
          - container: step-wait-for-vmi-status
            imageID: >-
              registry.redhat.io/container-native-virtualization/kubevirt-tekton-tasks-wait-for-vmi-status@sha256:0e1a1826e58053a449cd5475295d5717c40e64d3964c3a781dd198705b087ac9
            name: wait-for-vmi-status
            terminated:
              exitCode: 1
              finishedAt: '2023-02-13T19:05:02Z'
              reason: TaskRunCancelled
              startedAt: '2023-02-13T18:05:24Z'
        taskSpec:
          params:
            - description: Name of a VirtualMachineInstance to wait for.
              name: vmiName
              type: string
            - default: ''
              description: >-
                Namespace of a VirtualMachineInstance to wait for. (defaults to
                manifest namespace or active namespace)
              name: vmiNamespace
              type: string
            - default: ''
              description: >-
                A label selector expression to decide if the
                VirtualMachineInstance (VMI) is in a success state. Eg.
                "status.phase == Succeeded". It is evaluated on each VMI update
                and will result in this task succeeding if true.
              name: successCondition
              type: string
            - default: ''
              description: >-
                A label selector expression to decide if the
                VirtualMachineInstance (VMI) is in a failed state. Eg.
                "status.phase in (Failed, Unknown)". It is evaluated on each VMI
                update and will result in this task failing if true.
              name: failureCondition
              type: string
          steps:
            - command:
                - entrypoint
              env:
                - name: VMI_NAME
                  value: windows-4liy4a
                - name: VMI_NAMESPACE
                - name: SUCCESS_CONDITION
                  value: status.phase == Succeeded
                - name: FAILURE_CONDITION
                  value: 'status.phase in (Failed, Unknown)'
              image: >-
                registry.redhat.io/container-native-virtualization/kubevirt-tekton-tasks-wait-for-vmi-status@sha256:fc61bcd629c680f2d61150a308247b5ceda9c370f566112338ac534e05c95a2f
              name: wait-for-vmi-status
              resources: {}