2020-04-20 15:48:59 -06:00
|
|
|
apiVersion: batch/v1
|
|
|
|
|
kind: Job
|
|
|
|
|
metadata:
|
|
|
|
|
name: rook-ceph-toolbox-job
|
2020-12-09 13:21:15 -07:00
|
|
|
namespace: rook-ceph # namespace:cluster
|
2020-04-20 15:48:59 -06:00
|
|
|
labels:
|
|
|
|
|
app: ceph-toolbox-job
|
|
|
|
|
spec:
|
|
|
|
|
template:
|
|
|
|
|
spec:
|
|
|
|
|
initContainers:
|
2021-03-08 12:18:21 +05:30
|
|
|
- name: config-init
|
2024-08-08 22:10:07 -04:00
|
|
|
image: docker.io/rook/ceph:master
|
2021-03-08 12:18:21 +05:30
|
|
|
command: ["/usr/local/bin/toolbox.sh"]
|
|
|
|
|
args: ["--skip-watch"]
|
|
|
|
|
imagePullPolicy: IfNotPresent
|
|
|
|
|
env:
|
|
|
|
|
- name: ROOK_CEPH_USERNAME
|
|
|
|
|
valueFrom:
|
|
|
|
|
secretKeyRef:
|
|
|
|
|
name: rook-ceph-mon
|
|
|
|
|
key: ceph-username
|
|
|
|
|
volumeMounts:
|
|
|
|
|
- mountPath: /etc/ceph
|
|
|
|
|
name: ceph-config
|
|
|
|
|
- name: mon-endpoint-volume
|
|
|
|
|
mountPath: /etc/rook
|
2022-12-14 16:15:12 -07:00
|
|
|
- name: ceph-admin-secret
|
|
|
|
|
mountPath: /var/lib/rook-ceph-mon
|
2025-11-17 06:54:07 -06:00
|
|
|
- name: rook-config-override
|
|
|
|
|
mountPath: /etc/rook-config-override
|
|
|
|
|
readOnly: true
|
2020-04-20 15:48:59 -06:00
|
|
|
containers:
|
2021-03-08 12:18:21 +05:30
|
|
|
- name: script
|
2024-08-08 22:10:07 -04:00
|
|
|
image: docker.io/rook/ceph:master
|
2021-03-08 12:18:21 +05:30
|
|
|
volumeMounts:
|
|
|
|
|
- mountPath: /etc/ceph
|
|
|
|
|
name: ceph-config
|
|
|
|
|
readOnly: true
|
|
|
|
|
command:
|
|
|
|
|
- "bash"
|
|
|
|
|
- "-c"
|
|
|
|
|
- |
|
|
|
|
|
# Modify this script to run any ceph, rbd, radosgw-admin, or other commands that could
|
|
|
|
|
# be run in the toolbox pod. The output of the commands can be seen by getting the pod log.
|
|
|
|
|
#
|
|
|
|
|
# example: print the ceph status
|
|
|
|
|
ceph status
|
2020-04-20 15:48:59 -06:00
|
|
|
volumes:
|
2022-12-14 16:15:12 -07:00
|
|
|
- name: ceph-admin-secret
|
|
|
|
|
secret:
|
|
|
|
|
secretName: rook-ceph-mon
|
|
|
|
|
optional: false
|
|
|
|
|
items:
|
|
|
|
|
- key: ceph-secret
|
|
|
|
|
path: secret.keyring
|
2021-03-08 12:18:21 +05:30
|
|
|
- name: mon-endpoint-volume
|
|
|
|
|
configMap:
|
|
|
|
|
name: rook-ceph-mon-endpoints
|
|
|
|
|
items:
|
|
|
|
|
- key: data
|
|
|
|
|
path: mon-endpoints
|
2025-11-17 06:54:07 -06:00
|
|
|
- name: rook-config-override
|
|
|
|
|
configMap:
|
|
|
|
|
name: rook-config-override
|
|
|
|
|
optional: true
|
2021-03-08 12:18:21 +05:30
|
|
|
- name: ceph-config
|
|
|
|
|
emptyDir: {}
|
2020-04-20 15:48:59 -06:00
|
|
|
restartPolicy: Never
|