-
Notifications
You must be signed in to change notification settings - Fork 53
Open
Description
While testing things in a Kubernetes environment, it is convenient to start a container that keeps running and can be used for multiple ceph-nvmeof
commands. Currentlty the ceph-nvmeof
is not available, so I'm using a workaround to have a script in my deployed Pod.
---
apiVersion: v1
kind: Pod
metadata:
labels:
app: nvmeof-cli
name: nvmeof-cli
spec:
containers:
- command:
- sh
- -c
- "echo '#!/bin/sh\nexec python3 -m control.cli $@' > /usr/local/bin/ceph-nvmeof && chmod +x /usr/local/bin/ceph-nvmeof && tail -f /dev/null"
image: quay.io/ceph/nvmeof-cli:latest
imagePullPolicy: IfNotPresent
name: nvmeof-cli
When creating the above Pod, a small script /usr/local/bin/ceph-nvmeof
is created, and the main process is blocked on fail -f /dev/null
so that the Pod keeps available for additional kubectl exec
commands.
It would be nice if I can drop the workaround, and the ceph-nvmeof
command is directly available in the $PATH
.
Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Status
🆕 New