Revision d2baa21d daemons/daemon-util.in
b/daemons/daemon-util.in | ||
---|---|---|
36 | 36 |
echo "@LOCALSTATEDIR@/run/ganeti/$1.pid" |
37 | 37 |
} |
38 | 38 |
|
39 |
# Checks whether the local machine is part of a cluster |
|
40 |
check_config() { |
|
41 |
local server_pem=@LOCALSTATEDIR@/lib/ganeti/server.pem |
|
42 |
local fname |
|
43 |
|
|
44 |
for fname in $server_pem; do |
|
45 |
if [[ ! -f $fname ]]; then |
|
46 |
echo "Missing configuration file $fname" >&2 |
|
47 |
return 1 |
|
48 |
fi |
|
49 |
done |
|
50 |
|
|
51 |
return 0 |
|
52 |
} |
|
53 |
|
|
39 | 54 |
# Checks whether daemon is running |
40 | 55 |
check() { |
41 | 56 |
if [[ "$#" -lt 1 ]]; then |
Also available in: Unified diff