apiVersion: batch/v1
kind: Job
metadata:
  creationTimestamp: "2024-05-01T18:20:39Z"
  generation: 1
  labels:
    batch.kubernetes.io/controller-uid: 2354bce3-28da-41bb-8345-341249760b2b
    batch.kubernetes.io/job-name: osc-podvm-image-creation
    controller-uid: 2354bce3-28da-41bb-8345-341249760b2b
    job-name: osc-podvm-image-creation
  name: osc-podvm-image-creation
  namespace: openshift-sandboxed-containers-operator
  resourceVersion: "84672"
  uid: 2354bce3-28da-41bb-8345-341249760b2b
spec:
  backoffLimit: 1
  completionMode: NonIndexed
  completions: 1
  parallelism: 1
  selector:
    matchLabels:
      batch.kubernetes.io/controller-uid: 2354bce3-28da-41bb-8345-341249760b2b
  suspend: false
  template:
    metadata:
      creationTimestamp: null
      labels:
        batch.kubernetes.io/controller-uid: 2354bce3-28da-41bb-8345-341249760b2b
        batch.kubernetes.io/job-name: osc-podvm-image-creation
        controller-uid: 2354bce3-28da-41bb-8345-341249760b2b
        job-name: osc-podvm-image-creation
      name: osc-podvm-image-creation
    spec:
      containers:
      - command:
        - /podvm-builder.sh
        - create
        envFrom:
        - secretRef:
            name: peer-pods-secret
        - configMapRef:
            name: peer-pods-cm
            optional: true
        - configMapRef:
            name: azure-podvm-image-cm
            optional: true
        - configMapRef:
            name: aws-podvm-image-cm
            optional: true
        image: registry.redhat.io/openshift-sandboxed-containers/osc-podvm-builder-rhel9:latest
        imagePullPolicy: Always
        name: create
        resources: {}
        securityContext:
          runAsUser: 0
        terminationMessagePath: /dev/termination-log
        terminationMessagePolicy: File
        volumeMounts:
        - mountPath: /payload
          name: payload
      dnsPolicy: ClusterFirst
      initContainers:
      - args:
        - |
          echo "Copying the payload files"
          cp /podvm-binaries.tar.gz /payload/podvm-binaries.tar.gz || exit 1
          echo "Copied the payload files successfully"
        command:
        - /bin/sh
        - -c
        image: registry.redhat.io/openshift-sandboxed-containers/osc-podvm-payload-rhel9:latest
        imagePullPolicy: Always
        name: copy
        resources: {}
        terminationMessagePath: /dev/termination-log
        terminationMessagePolicy: File
        volumeMounts:
        - mountPath: /payload
          name: payload
      restartPolicy: Never
      schedulerName: default-scheduler
      securityContext: {}
      terminationGracePeriodSeconds: 30
      volumes:
      - emptyDir: {}
        name: payload
status:
  active: 1
  ready: 1
  startTime: "2024-05-01T18:20:39Z"
  uncountedTerminatedPods: {}
