]> git.sur5r.net Git - bacula/bacula/blob - bacula/src/qt-console/tray-monitor/tray_conf.h
38320a0c68598cf2fd1e2408bdd166189b653ca0
[bacula/bacula] / bacula / src / qt-console / tray-monitor / tray_conf.h
1 /*
2    Bacula(R) - The Network Backup Solution
3
4    Copyright (C) 2000-2015 Kern Sibbald
5    Copyright (C) 2004-2014 Free Software Foundation Europe e.V.
6
7    The original author of Bacula is Kern Sibbald, with contributions
8    from many others, a complete list can be found in the file AUTHORS.
9
10    You may use this file and others of this release according to the
11    license defined in the LICENSE file, which includes the Affero General
12    Public License, v3.0 ("AGPLv3") and some additional permissions and
13    terms pursuant to its AGPLv3 Section 7.
14
15    This notice must be preserved when any source code is 
16    conveyed and/or propagated.
17
18    Bacula(R) is a registered trademark of Kern Sibbald.
19 */
20 /*
21  * Tray Monitor specific configuration and defines
22  *
23  *   Adapted from dird_conf.c
24  *
25  *     Nicolas Boichat, August MMIV
26  *
27  */
28
29 /* NOTE:  #includes at the end of this file */
30
31 /*
32  * Resource codes -- they must be sequential for indexing
33  */
34 enum rescode {
35    R_MONITOR = 1001,
36    R_DIRECTOR,
37    R_CLIENT,
38    R_STORAGE,
39    R_CONSOLE_FONT,
40    R_FIRST = R_MONITOR,
41    R_LAST  = R_CONSOLE_FONT                /* keep this updated */
42 };
43
44
45 /*
46  * Some resource attributes
47  */
48 enum {
49    R_NAME = 1020,
50    R_ADDRESS,
51    R_PASSWORD,
52    R_TYPE,
53    R_BACKUP
54 };
55
56 /* Director */
57 struct DIRRES {
58    RES   hdr;
59    uint32_t DIRport;                  /* UA server port */
60    char *address;                     /* UA server address */
61    bool enable_ssl;                   /* Use SSL */
62 };
63
64 /*
65  *   Tray Monitor Resource
66  *
67  */
68 struct MONITOR {
69    RES   hdr;
70    bool require_ssl;                  /* Require SSL for all connections */
71    MSGS *messages;                    /* Daemon message handler */
72    char *password;                    /* UA server password */
73    utime_t RefreshInterval;           /* Status refresh interval */
74    utime_t FDConnectTimeout;          /* timeout for connect in seconds */
75    utime_t SDConnectTimeout;          /* timeout in seconds */
76    utime_t DIRConnectTimeout;         /* timeout in seconds */
77 };
78
79
80 /*
81  *   Client Resource
82  *
83  */
84 struct CLIENT {
85    RES   hdr;
86
87    uint32_t FDport;                   /* Where File daemon listens */
88    char *address;
89    char *password;
90    bool enable_ssl;                   /* Use SSL */
91 };
92
93 /*
94  *   Store Resource
95  *
96  */
97 struct STORE {
98    RES   hdr;
99
100    uint32_t SDport;                   /* port where Directors connect */
101    char *address;
102    char *password;
103    bool enable_ssl;                   /* Use SSL */
104 };
105
106 struct CONFONTRES {
107    RES   hdr;
108    char *fontface;                    /* Console Font specification */
109 };
110
111 /* Define the Union of all the above
112  * resource structure definitions.
113  */
114 union URES {
115    MONITOR    res_monitor;
116    DIRRES     res_dir;
117    CLIENT     res_client;
118    STORE      res_store;
119    CONFONTRES con_font;
120    RES        hdr;
121 };