Add ceph-mgr-create

This commit is contained in:
Nico Schottelius 2018-02-15 23:59:55 +01:00
parent aeeeb2ba7e
commit d0ed1b50d7
2 changed files with 20 additions and 0 deletions

0
ceph-host-move-to-root Normal file → Executable file
View file

20
ceph-mgr-create Executable file
View file

@ -0,0 +1,20 @@
#!/bin/sh
name=$(hostname)
CEPH_PATH=/var/lib/ceph
MGR_PATH=$CEPH_PATH/mgr/ceph-$name
if [ -e "$MGR_PATH" ]; then
echo "$MGR_PATH exists - aborting"
exit 1
fi
mkdir "$MGR_PATH"
chown ceph:ceph "$MGR_PATH"
touch "$MGR_PATH/sysvinit"
ceph auth get-or-create mgr.$name \
mon 'allow profile mgr' \
osd 'allow *' \
mds 'allow *' > "$MGR_PATH/keyring"