]>
Commit | Line | Data |
---|---|---|
7c673cae FG |
1 | description "Ceph MON (start all instances)" |
2 | ||
3 | start on starting ceph-mon-all | |
4 | ||
5 | task | |
6 | ||
7 | script | |
8 | set -e | |
9 | # TODO what's the valid charset for cluster names and mon ids? | |
10 | find -L /var/lib/ceph/mon/ -mindepth 1 -maxdepth 1 -regextype posix-egrep -regex '.*/[A-Za-z0-9]+-[A-Za-z0-9._-]+' -printf '%P\n' \ | |
11 | | while read f; do | |
12 | if [ -e "/var/lib/ceph/mon/$f/done" ] && [ -e "/var/lib/ceph/mon/$f/upstart" ] && [ ! -e "/var/lib/ceph/mon/$f/sysvinit" ]; then | |
13 | cluster="${f%%-*}" | |
14 | id="${f#*-}" | |
15 | ||
16 | initctl emit ceph-mon cluster="$cluster" id="$id" | |
17 | fi | |
18 | done | |
19 | end script |