]> git.sur5r.net Git - bacula/bacula/blob - regress/scripts/bacula-dir.conf.testrunscript.in
Delete unwanted subdirectory
[bacula/bacula] / regress / scripts / bacula-dir.conf.testrunscript.in
1 #
2 # Default Bacula Director Configuration file
3 #
4 #  The only thing that MUST be changed is to add one or more
5 #   file or directory names in the Include directive of the
6 #   FileSet resource.
7 #
8 #  For Bacula release 1.39.27 (24 October 2006) -- debian testing/unstable
9 #
10 #  You might also want to change the default email address
11 #   from root to your address.  See the "mail" and "operator"
12 #   directives in the Messages resource.
13 #
14
15 Director {                            # define myself
16   Name = @hostname@-dir
17   DIRport = 8101                # where we listen for UA connections
18   QueryFile = "@scriptdir@/query.sql"
19   WorkingDirectory = "@working_dir@"
20   PidDirectory = "@piddir@"
21   SubSysDirectory = "@subsysdir@"
22   Maximum Concurrent Jobs = 4
23   Password = "pNvX1WiXnwv2C/F7E52LGvw6rKjbbPvu2kyuPa9pVaL3"         # Console password
24   Messages = Standard
25 }
26
27 JobDefs {
28   Name = "DefaultJob"
29   Type = Backup
30   Level = Incremental
31   Client = @hostname@-fd 
32   FileSet = FS_TESTJOB
33   Storage = File
34   Messages = Standard
35   Pool = Default
36   Priority = 10
37   Maximum Concurrent Jobs = 16
38 }
39
40 FileSet {
41  Name = FS_TESTJOB
42  Include {
43    File=</tmp/file-list
44  }
45 }
46
47 #dir: BeforeJob: run command "/bin/echo RunBeforeJob"
48 #fd: ClientRunBeforeJob: ClientRunBeforeJob
49 #fd: ClientAfterJob: run command "/bin/echo ClientRunAfterJob"
50 #dir: AfterJob: run command "/bin/echo RunAfterJob"
51
52 Job {
53   Name = "RUN_ALL_OK"
54   JobDefs = DefaultJob
55   FileSet = FS_TESTJOB
56   RunBeforeJob = "/bin/echo RunBeforeJob"
57   ClientRunBeforeJob = "/bin/echo ClientRunBeforeJob"
58   Run After Job = "/bin/echo RunAfterJob"
59   ClientRunAfterJob = "/bin/echo ClientRunAfterJob"
60 }
61
62 #After job are after before job
63 Job {
64   Name = "RUN_DIR_FAILED_BUG"
65   FileSet = FS_TESTJOB  
66   JobDefs = DefaultJob
67   Run After Failed Job = "/bin/echo RunAfterFailedJob"
68   RunBeforeJob = "/bin/false"
69 }
70
71 #@hostname@-dir: BeforeJob: run command "/bin/false"
72 #@hostname@-dir: BeforeJob: RunAfterFailedJob
73 Job {
74   Name = "RUN_DIR_FAILED"
75   FileSet = FS_TESTJOB  
76   JobDefs = DefaultJob
77   RunBeforeJob = "/bin/false RUN_DIR_FAILED"
78   Run After Failed Job = "/bin/echo RunAfterFailedJob"
79 }
80
81 #@hostname@-fd: ClientBeforeJob: run command "/bin/false RUN_FD_FAILED1"
82 #@hostname@-fd: ClientBeforeJob: run command "/bin/false RUN_FD_FAILED2"
83 #@hostname@-dir: AfterJob: run command "/bin/echo RunAfterFailedJob"
84 Job {
85   Name = "RUN_FD_FAILED"
86   FileSet = FS_TESTJOB  
87   JobDefs = DefaultJob
88   RunScript {
89     Command = "/bin/false RUN_FD_FAILED1"
90     failjobonerror = no
91     RunsWhen = Before
92   }
93   RunScript {
94     Command = "/bin/false RUN_FD_FAILED2"
95     failjobonerror = yes
96     RunsWhen = Before
97   }
98
99   Run After Failed Job = "/bin/echo RunAfterFailedJob"
100   RunScript {
101     Command = "/bin/echo touching @tmpdir@/RUN_FD_FAILED"
102     RunsWhen = after
103     RunsOnFailure = yes
104   }
105   RunScript {
106     Command = "/bin/touch @tmpdir@/RUN_FD_FAILED"
107     RunsWhen = after
108     RunsOnFailure = yes
109   }
110 }
111
112 #@hostname@-fd: ClientBeforeJob: run command "/bin/false RUN_FD_FAILED1"
113 #we dont execute FAILED2 
114 #@hostname@-dir: AfterJob: run command "/bin/echo RunAfterFailedJob"
115 Job {
116   Name = "RUN_FD_FAILED2"
117   FileSet = FS_TESTJOB  
118   JobDefs = DefaultJob
119   RunScript {
120     Command = "/bin/false RUN_FD_FAILED1"
121     failjobonerror = yes
122     RunsWhen = Before
123   }
124   RunScript {
125     Command = "/bin/false RUN_FD_FAILED2"
126     failjobonerror = yes
127     RunsWhen = Before
128   }
129   RunScript {
130     Command = "/bin/false RUN_FD_FAILED3"
131     failjobonerror = yes
132     RunsOnFailure = yes
133     RunsWhen = Before
134   }
135
136   Run After Failed Job = "/bin/echo RunAfterFailedJob"
137 }
138
139 #@hostname@-fd: ClientBeforeJob: run command "/bin/false RUN_FD_WARNING"
140 #Backup OK -- with warnings
141 Job {
142   Name = "RUN_FD_WARNING"
143   FileSet = FS_TESTJOB  
144   JobDefs = DefaultJob
145   RunScript {
146     Command = "/bin/false RUN_FD_WARNING"
147     failjobonerror = no
148     RunsWhen = Before
149   }
150   Run After Failed Job = "/bin/echo RunAfterFailedJob"
151 }
152
153 FileSet {
154  Name = FS_FIFO
155  Include {
156    Options { readfifo = yes }
157    File=</tmp/file-list
158  }
159 }
160
161 Job {
162   Name = BUG_897
163   JobDefs = DefaultJob
164   FileSet = FS_FIFO
165
166   RunScript {
167     Command = "/bin/echo touching /tmp/RUN_BUG_897"
168     RunsWhen = after
169     RunsOnFailure = yes
170   }
171   RunScript {
172     Command = "/bin/touch /tmp/RUN_BUG_897"
173     RunsWhen = after
174     RunsOnFailure = yes
175   }
176 }
177
178 # Client (File Services) to backup
179 Client {
180   Name = @hostname@-fd
181   Address = @hostname@
182   FDPort = 8102
183   Catalog = MyCatalog
184   Password = "xevrjURYoCHhn26RaJoWbeWXEY/a3VqGKp/37tgWiuHc"          # password for FileDaemon
185   File Retention = 30d                # 30 days
186   Job Retention = 180d                # six months
187   AutoPrune = yes                     # Prune expired Jobs/Files
188   Maximum Concurrent Jobs = 4
189 }
190
191 # Definiton of file storage device
192 Storage {
193   Name = File
194   Address = @hostname@                # N.B. Use a fully qualified name here
195   SDPort = 8103
196   Password = "ccV3lVTsQRsdIUGyab0N4sMDavui2hOBkmpBU0aQKOr9"
197   Device = FileStorage
198   Media Type = File
199   Maximum Concurrent Jobs = 4
200 }
201
202 # Generic catalog service
203 Catalog {
204   Name = MyCatalog
205   dbname = regress; user = regress; password = ""
206 }
207
208
209 Messages {
210   Name = Standard
211   console = all, !skipped, !saved
212 }
213
214 # Default pool definition
215 Pool {
216   Name = Default
217   Pool Type = Backup
218   Recycle = yes                       # Bacula can automatically recycle Volumes
219   AutoPrune = yes                     # Prune expired volumes
220   Volume Retention = 365d             # one year
221 }