Debian Codegraph @

tools/ocft/nfsserver

raw ◀ ▶
Source reconstructed at patch state 0 of 1 — not the installed (fully patched) source.
1 Debian patch touch this file
1 # nfsserver
2
3 CONFIG
4 Agent nfsserver
5 AgentRoot /usr/lib/ocf/resource.d/heartbeat
6 InstallPackage nfs-kernel-server
7 HangTimeout 20
8
9 SETUP-AGENT
10 INITSCRIPT=""
11 if test -f /etc/init.d/nfsserver; then
12 INITSCRIPT="/etc/init.d/nfsserver"
13 fi
14 true
15
16 CASE-BLOCK required_args
17 Env OCF_RESKEY_nfs_init_script=$INITSCRIPT
18
19 CASE-BLOCK default_status
20 AgentRun stop
21
22 CASE-BLOCK prepare
23 Include required_args
24 Include default_status
25
26 CASE "check base env"
27 Include prepare
28 AgentRun start OCF_SUCCESS
29
30 CASE "check base env: invalid 'OCF_RESKEY_nfs_notify_cmd'"
31 Include prepare
32 Env OCF_RESKEY_nfs_notify_cmd=no_such_program
33 AgentRun start OCF_ERR_INSTALLED
34
35 CASE "normal start"
36 Include prepare
37 AgentRun start OCF_SUCCESS
38
39 CASE "normal stop"
40 Include prepare
41 AgentRun start
42 AgentRun stop OCF_SUCCESS
43
44 CASE "double start"
45 Include prepare
46 AgentRun start
47 AgentRun start OCF_SUCCESS
48
49 CASE "double stop"
50 Include prepare
51 AgentRun stop OCF_SUCCESS
52
53 CASE "monitor with running"
54 Include prepare
55 AgentRun start
56 AgentRun monitor OCF_SUCCESS
57
58 CASE "monitor with not running"
59 Include prepare
60 AgentRun monitor OCF_NOT_RUNNING
61
62 CASE "unimplemented command"
63 Include prepare
64 AgentRun no_cmd OCF_ERR_UNIMPLEMENTED