apiVersion: batch/v1
kind: Job
metadata:
  annotations:
    helm.sh/hook: post-install,post-upgrade
    openstackhelm.openstack.org/release_uuid: ""
  creationTimestamp: "2026-04-09T02:23:09Z"
  generation: 1
  labels:
    application: glance
    component: storage-init
    release_group: glance
  name: glance-storage-init
  namespace: openstack
  resourceVersion: "9968"
  uid: 5aec660e-aae7-4df7-85f9-11d21819ced5
spec:
  backoffLimit: 6
  completionMode: NonIndexed
  completions: 1
  parallelism: 1
  selector:
    matchLabels:
      batch.kubernetes.io/controller-uid: 5aec660e-aae7-4df7-85f9-11d21819ced5
  suspend: false
  template:
    metadata:
      annotations:
        openstackhelm.openstack.org/release_uuid: ""
      creationTimestamp: null
      labels:
        application: glance
        batch.kubernetes.io/controller-uid: 5aec660e-aae7-4df7-85f9-11d21819ced5
        batch.kubernetes.io/job-name: glance-storage-init
        component: storage-init
        controller-uid: 5aec660e-aae7-4df7-85f9-11d21819ced5
        job-name: glance-storage-init
        release_group: glance
    spec:
      containers:
      - command:
        - /tmp/storage-init.sh
        env:
        - name: NAMESPACE
          valueFrom:
            fieldRef:
              apiVersion: v1
              fieldPath: metadata.namespace
        - name: STORAGE_BACKEND
          value: rbd
        - name: RBD_POOL_NAME
          value: glance.images
        - name: RBD_POOL_APP_NAME
          value: glance-image
        - name: RBD_POOL_USER
          value: glance
        - name: RBD_POOL_REPLICATION
          value: "1"
        - name: RBD_POOL_CRUSH_RULE
          value: replicated_rule
        - name: RBD_POOL_CHUNK_SIZE
          value: "8"
        - name: RBD_POOL_SECRET
          value: images-rbd-keyring
        image: harbor.atmosphere.dev/ghcr.io/vexxhost/glance:2024.1@sha256:96bf0fc8c48f051f2f8afa4541b64dc58e9f017868c53389ca8a5972e563d837
        imagePullPolicy: IfNotPresent
        name: glance-storage-init
        resources: {}
        securityContext:
          allowPrivilegeEscalation: false
          readOnlyRootFilesystem: true
        terminationMessagePath: /dev/termination-log
        terminationMessagePolicy: File
        volumeMounts:
        - mountPath: /tmp
          name: pod-tmp
        - mountPath: /tmp/storage-init.sh
          name: glance-bin
          readOnly: true
          subPath: storage-init.sh
        - mountPath: /etc/ceph
          name: etcceph
        - mountPath: /etc/ceph/ceph.conf
          name: ceph-etc
          readOnly: true
          subPath: ceph.conf
        - mountPath: /tmp/client-keyring
          name: ceph-keyring
          readOnly: true
          subPath: key
      dnsPolicy: ClusterFirst
      initContainers:
      - command:
        - kubernetes-entrypoint
        env:
        - name: POD_NAME
          valueFrom:
            fieldRef:
              apiVersion: v1
              fieldPath: metadata.name
        - name: NAMESPACE
          valueFrom:
            fieldRef:
              apiVersion: v1
              fieldPath: metadata.namespace
        - name: INTERFACE_NAME
          value: eth0
        - name: PATH
          value: /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/
        - name: DEPENDENCY_SERVICE
        - name: DEPENDENCY_JOBS
          value: glance-ks-user
        - name: DEPENDENCY_DAEMONSET
        - name: DEPENDENCY_CONTAINER
        - name: DEPENDENCY_POD_JSON
        - name: DEPENDENCY_CUSTOM_RESOURCE
        image: harbor.atmosphere.dev/ghcr.io/vexxhost/kubernetes-entrypoint:edge@sha256:8921b64b87af184a1421dd856b2703bcf3cff9f50863cd0d18371cf964a87bd3
        imagePullPolicy: IfNotPresent
        name: init
        resources: {}
        securityContext:
          allowPrivilegeEscalation: false
          readOnlyRootFilesystem: true
          runAsUser: 65534
        terminationMessagePath: /dev/termination-log
        terminationMessagePolicy: File
      - command:
        - /tmp/ceph-admin-keyring.sh
        image: harbor.atmosphere.dev/ghcr.io/vexxhost/glance:2024.1@sha256:96bf0fc8c48f051f2f8afa4541b64dc58e9f017868c53389ca8a5972e563d837
        imagePullPolicy: IfNotPresent
        name: ceph-keyring-placement
        resources: {}
        securityContext:
          allowPrivilegeEscalation: false
          readOnlyRootFilesystem: true
        terminationMessagePath: /dev/termination-log
        terminationMessagePolicy: File
        volumeMounts:
        - mountPath: /tmp
          name: pod-tmp
        - mountPath: /etc/ceph
          name: etcceph
        - mountPath: /tmp/ceph-admin-keyring.sh
          name: glance-bin
          readOnly: true
          subPath: ceph-admin-keyring.sh
        - mountPath: /tmp/client-keyring
          name: ceph-keyring
          readOnly: true
          subPath: key
      nodeSelector:
        openstack-control-plane: enabled
      restartPolicy: OnFailure
      schedulerName: default-scheduler
      securityContext:
        runAsUser: 42424
      serviceAccount: glance-storage-init
      serviceAccountName: glance-storage-init
      terminationGracePeriodSeconds: 30
      volumes:
      - emptyDir: {}
        name: pod-tmp
      - configMap:
          defaultMode: 365
          name: glance-bin
        name: glance-bin
      - emptyDir: {}
        name: etcceph
      - configMap:
          defaultMode: 292
          name: ceph-etc
        name: ceph-etc
      - name: ceph-keyring
        secret:
          defaultMode: 420
          secretName: pvc-ceph-client-key
status:
  completionTime: "2026-04-09T02:23:24Z"
  conditions:
  - lastProbeTime: "2026-04-09T02:23:24Z"
    lastTransitionTime: "2026-04-09T02:23:24Z"
    status: "True"
    type: Complete
  ready: 0
  startTime: "2026-04-09T02:23:09Z"
  succeeded: 1
  uncountedTerminatedPods: {}
