add netconfig aspect to rpm
[raven.git] / rpm_builds / SPECS / gackscentral.spec.template
1 Summary: Gacks Central
2 Name: gackscentral
3 Version: @VER@
4 Release: @REL@
5 License: Public Domain
6 Group: Raven at U of Arizona
7 URL: http://www.cs.arizona.edu/
8 Source RPM: ftp://quadrus.cs.arizona.edu/PlanetLab/V3/gackscentral-@VER@.tar.gz
9 Vendor: University of Arizona
10 BuildRoot: %{_tmppath}/%{name}-root
11 requires: arizona-lib >= 2.2.8, httpd
12
13 %description
14 This rpm provides gacks central.
15 %prep
16 %setup -q
17
18 %build
19
20 %install
21 rm -rf %\{buildroot]
22 install -d -o 0 -g 0 %{buildroot}/usr
23 install -d -o 0 -g 0 %{buildroot}/usr/local/gackscentral
24 install -d -o 0 -g 0 %{buildroot}/usr/local/gackscentral/bin
25 #install -d -o 0 -g 0 %{buildroot}/usr/local/gackscentral/bin/sfa
26 #install -d -o 0 -g 0 %{buildroot}/usr/local/gackscentral/bin/sfa/trust
27 #install -d -o 0 -g 0 %{buildroot}/usr/local/gackscentral/bin/sfa/util
28 install -d -o 0 -g 0 %{buildroot}/usr/local/gackscentral/scripts
29 install -d -o 0 -g 0 %{buildroot}/usr/local/gackscentral/var
30 install -d -o 0 -g 0 %{buildroot}/usr/local/gackscentral/var/trusted_roots
31 install -d -o 0 -g 0 %{buildroot}/usr/local/gackscentral/var/log
32
33 install -d -o 0 -g 0 %{buildroot}/usr
34 install -d -o 0 -g 0 %{buildroot}/usr/share
35 install -d -o 0 -g 0 %{buildroot}/usr/share/plc_api
36 install -d -o 0 -g 0 %{buildroot}/usr/share/plc_api/aspects
37 install -d -o 0 -g 0 %{buildroot}/usr/share/plc_api/PLC
38 install -d -o 0 -g 0 %{buildroot}/usr/share/plc_api/PLC/Methods
39
40 install -d -o 0 -g 0 %{buildroot}/usr
41 install -d -o 0 -g 0 %{buildroot}/usr/lib
42 install -d -o 0 -g 0 %{buildroot}/usr/lib/python2.6
43 install -d -o 0 -g 0 %{buildroot}/usr/lib/python2.6/site-packages
44
45 install -d -o 0 -g 0 %{buildroot}/var
46 install -d -o 0 -g 0 %{buildroot}/var/log
47 install -d -o 0 -g 0 %{buildroot}/var/log/gacks
48
49 install -d -o 0 -g 0 %{buildroot}/etc
50 install -d -o 0 -g 0 %{buildroot}/etc/httpd
51 install -d -o 0 -g 0 %{buildroot}/etc/httpd/conf.d
52
53 install -d -o 0 -g 0 %{buildroot}/etc/cron.d
54 install -d -o 0 -g 0 %{buildroot}/etc/init.d
55
56 install -d -o 0 -g 0 %{buildroot}/etc/gacks
57
58 install gacks-api.conf %{buildroot}/etc/httpd/conf.d
59
60 install API.py %{buildroot}/usr/local/gackscentral/bin
61 install ModPython.py %{buildroot}/usr/local/gackscentral/bin
62 install BaseApi.py %{buildroot}/usr/local/gackscentral/bin
63 install AuthenticatedApi.py %{buildroot}/usr/local/gackscentral/bin
64 install ApiExceptionCodes.py  %{buildroot}/usr/local/gackscentral/bin
65
66 install testGacksCalendar.py %{buildroot}/usr/local/gackscentral/bin
67 install gacksaccount.py %{buildroot}/usr/local/gackscentral/bin
68 install gacksaccountmanager.py %{buildroot}/usr/local/gackscentral/bin
69 install gacksaccount_test.py %{buildroot}/usr/local/gackscentral/bin
70 install gacksauth.py %{buildroot}/usr/local/gackscentral/bin
71 install gacksbilling.py %{buildroot}/usr/local/gackscentral/bin
72 install gacksid.py %{buildroot}/usr/local/gackscentral/bin
73 install gacksreset.py %{buildroot}/usr/local/gackscentral/bin
74 install gacksbackend.py %{buildroot}/usr/local/gackscentral/bin
75 install gackscalendar.py %{buildroot}/usr/local/gackscentral/bin
76 install gackscalendar_list.py %{buildroot}/usr/local/gackscentral/bin
77 install gackscalendar_mysql.py %{buildroot}/usr/local/gackscentral/bin
78 install gackscalendar_db.py %{buildroot}/usr/local/gackscentral/bin
79 install gackscli.py %{buildroot}/usr/local/gackscentral/bin
80 install gacksclient.py %{buildroot}/usr/local/gackscentral/bin
81 install gackscollector.py %{buildroot}/usr/local/gackscentral/bin
82 install gacksconfig.py %{buildroot}/usr/local/gackscentral/bin
83 install gacksdaemon.py %{buildroot}/usr/local/gackscentral/bin
84 install gacksdb.py %{buildroot}/usr/local/gackscentral/bin
85 install gacksexcep.py %{buildroot}/usr/local/gackscentral/bin
86 install gacksenforce.py %{buildroot}/usr/local/gackscentral/bin
87 install gackshandle.py %{buildroot}/usr/local/gackscentral/bin
88 install gackshandler_base.py %{buildroot}/usr/local/gackscentral/bin
89 install gackshandler_plc.py %{buildroot}/usr/local/gackscentral/bin
90 install gacksid.py %{buildroot}/usr/local/gackscentral/bin
91 install gacksinvoice.py %{buildroot}/usr/local/gackscentral/bin
92 install gackslogserver.py %{buildroot}/usr/local/gackscentral/bin
93 install gacksjob.py %{buildroot}/usr/local/gackscentral/bin
94 install gacksnodepicker.py %{buildroot}/usr/local/gackscentral/bin
95 install gacksnodestatus.py %{buildroot}/usr/local/gackscentral/bin
96 install gackspolicy.py %{buildroot}/usr/local/gackscentral/bin
97 install gacksqueue.py %{buildroot}/usr/local/gackscentral/bin
98 install gacksqueue_mysql.py %{buildroot}/usr/local/gackscentral/bin
99 install gacksreceipt.py %{buildroot}/usr/local/gackscentral/bin
100 install gacksresource.py %{buildroot}/usr/local/gackscentral/bin
101 install gacksrspec.py %{buildroot}/usr/local/gackscentral/bin
102 install gackstime.py %{buildroot}/usr/local/gackscentral/bin
103 install gackslog.py %{buildroot}/usr/local/gackscentral/bin
104 install gackslog_mysql.py %{buildroot}/usr/local/gackscentral/bin
105
106 install localhost-gacks-defragment.sh %{buildroot}/usr/local/gackscentral/bin
107 install localhost-gacks-garbagecollect.sh %{buildroot}/usr/local/gackscentral/bin
108 install localhost-gacks-runasap.sh %{buildroot}/usr/local/gackscentral/bin
109 install localhost-gacks-applyinvoices.sh %{buildroot}/usr/local/gackscentral/bin
110 install localhost-gacks-mailinvoices.sh %{buildroot}/usr/local/gackscentral/bin
111 install gackscentral.cron %{buildroot}/etc/cron.d
112
113 install gacksbackend.init %{buildroot}/etc/init.d
114 install gackslogserver.init %{buildroot}/etc/init.d
115 install gackscollector.init %{buildroot}/etc/init.d
116
117 install gackslog.conf %{buildroot}/etc/gacks
118
119 install bridgeconfig.py %{buildroot}/usr/share/plc_api/PLC
120 install netconfigaspects.py %{buildroot}/usr/share/plc_api/aspects
121 install SliceAutoConfig.py %{buildroot}/usr/share/plc_api/PLC/Methods
122 install SliceGetConfig.py %{buildroot}/usr/share/plc_api/PLC/Methods
123
124 # Geniwrapper stuff
125 #install __init__.py %{buildroot}/usr/local/gackscentral/bin/sfa
126 #install __init__.py %{buildroot}/usr/local/gackscentral/bin/sfa/trust
127 #install certificate.py %{buildroot}/usr/local/gackscentral/bin/sfa/trust
128 #install credential.py %{buildroot}/usr/local/gackscentral/bin/sfa/trust
129 #install gid.py %{buildroot}/usr/local/gackscentral/bin/sfa/trust
130 #install rights.py %{buildroot}/usr/local/gackscentral/bin/sfa/trust
131 #install trustedroot.py %{buildroot}/usr/local/gackscentral/bin/sfa/trust
132
133 #install __init__.py %{buildroot}/usr/local/gackscentral/bin/sfa/util
134 #install client.py %{buildroot}/usr/local/gackscentral/bin/sfa/util
135 #install faults.py %{buildroot}/usr/local/gackscentral/bin/sfa/util
136 #install sfaticket.py %{buildroot}/usr/local/gackscentral/bin/sfa/util
137 #install misc.py %{buildroot}/usr/local/gackscentral/bin/sfa/util
138 #install namespace.py %{buildroot}/usr/local/gackscentral/bin/sfa/util
139 #install parameter.py %{buildroot}/usr/local/gackscentral/bin/sfa/util
140 #install record.py %{buildroot}/usr/local/gackscentral/bin/sfa/util
141 #install report.py %{buildroot}/usr/local/gackscentral/bin/sfa/util
142 #install rspec.py %{buildroot}/usr/local/gackscentral/bin/sfa/util
143 #install xmlrpcprotocol.py %{buildroot}/usr/local/gackscentral/bin/sfa/util
144
145 %clean
146 rm -rf %{buildroot}
147
148 %post
149 mkdir -p /usr/local/gackscentral/var 2>/dev/null
150 mkdir -p /usr/local/gackscentral/var/log 2>/dev/null
151 mkdir -p /usr/local/gackscentral/var/trusted_roots 2>/dev/null
152
153 ln -sf /usr/local/gackscentral/bin/gackscli.py /usr/bin/gackscli
154
155 # apache can't seem to write the log files
156 chown -R apache /usr/local/gackscentral/var/log
157
158 chkconfig gacksbackend.init on
159 service gacksbackend.init restart
160 chkconfig gackslogserver.init on
161 service gackslogserver.init restart
162 chkconfig gackscollector.init on
163 service gackscollector.init restart
164
165 %preun
166 if [ $1 = 0 ]; then
167   rm -f /usr/bin/gackscli
168 fi
169
170 %files
171 %defattr(-,root,root)
172
173 /etc/httpd/conf.d/gacks-api.conf
174
175 /usr/local/gackscentral/bin/API.py
176 /usr/local/gackscentral/bin/ModPython.py
177 /usr/local/gackscentral/bin/BaseApi.py
178 /usr/local/gackscentral/bin/AuthenticatedApi.py
179 /usr/local/gackscentral/bin/ApiExceptionCodes.py
180
181 /usr/local/gackscentral/bin/testGacksCalendar.py
182 /usr/local/gackscentral/bin/gacksaccount.py
183 /usr/local/gackscentral/bin/gacksaccountmanager.py
184 /usr/local/gackscentral/bin/gacksaccount_test.py
185 /usr/local/gackscentral/bin/gacksauth.py
186 /usr/local/gackscentral/bin/gacksbilling.py
187 /usr/local/gackscentral/bin/gacksid.py
188 /usr/local/gackscentral/bin/gacksreset.py
189 /usr/local/gackscentral/bin/gacksbackend.py
190 /usr/local/gackscentral/bin/gackscalendar.py
191 /usr/local/gackscentral/bin/gackscalendar_list.py
192 /usr/local/gackscentral/bin/gackscalendar_mysql.py
193 /usr/local/gackscentral/bin/gackscalendar_db.py
194 /usr/local/gackscentral/bin/gackscli.py
195 /usr/local/gackscentral/bin/gacksclient.py
196 /usr/local/gackscentral/bin/gackscollector.py
197 /usr/local/gackscentral/bin/gacksconfig.py
198 /usr/local/gackscentral/bin/gacksdaemon.py
199 /usr/local/gackscentral/bin/gacksdb.py
200 /usr/local/gackscentral/bin/gacksenforce.py
201 /usr/local/gackscentral/bin/gacksexcep.py
202 /usr/local/gackscentral/bin/gackshandle.py
203 /usr/local/gackscentral/bin/gackshandler_base.py
204 /usr/local/gackscentral/bin/gackshandler_plc.py
205 /usr/local/gackscentral/bin/gacksid.py
206 /usr/local/gackscentral/bin/gacksinvoice.py
207 /usr/local/gackscentral/bin/gacksjob.py
208 /usr/local/gackscentral/bin/gacksnodepicker.py
209 /usr/local/gackscentral/bin/gacksnodestatus.py
210 /usr/local/gackscentral/bin/gackspolicy.py
211 /usr/local/gackscentral/bin/gacksqueue.py
212 /usr/local/gackscentral/bin/gacksqueue_mysql.py
213 /usr/local/gackscentral/bin/gacksreceipt.py
214 /usr/local/gackscentral/bin/gacksresource.py
215 /usr/local/gackscentral/bin/gacksrspec.py
216 /usr/local/gackscentral/bin/gackstime.py
217 /usr/local/gackscentral/bin/gackslog.py
218 /usr/local/gackscentral/bin/gackslog_mysql.py
219 /usr/local/gackscentral/bin/gackslogserver.py
220
221 /usr/share/plc_api/PLC/bridgeconfig.py
222 /usr/share/plc_api/aspects/netconfigaspects.py
223 /usr/share/plc_api/PLC/Methods/SliceAutoConfig.py
224 /usr/share/plc_api/PLC/Methods/SliceGetConfig.py
225
226 /usr/local/gackscentral/bin/localhost-gacks-defragment.sh
227 /usr/local/gackscentral/bin/localhost-gacks-garbagecollect.sh
228 /usr/local/gackscentral/bin/localhost-gacks-runasap.sh
229 /usr/local/gackscentral/bin/localhost-gacks-applyinvoices.sh
230 /usr/local/gackscentral/bin/localhost-gacks-mailinvoices.sh
231 %attr(0644,root,root) /etc/cron.d/gackscentral.cron
232
233 /etc/gacks/gackslog.conf
234
235 /etc/init.d/gacksbackend.init
236 %attr(0755,root,root) /etc/init.d/gacksbackend.init
237 /etc/init.d/gackslogserver.init
238 %attr(0755,root,root) /etc/init.d/gackslogserver.init
239 /etc/init.d/gackscollector.init
240 %attr(0755,root,root) /etc/init.d/gackscollector.init
241
242 # geniwrapper stuff
243 #/usr/local/gackscentral/bin/sfa/__init__.py
244 #/usr/local/gackscentral/bin/sfa/trust/__init__.py
245 #/usr/local/gackscentral/bin/sfa/trust/certificate.py
246 #/usr/local/gackscentral/bin/sfa/trust/credential.py
247 #/usr/local/gackscentral/bin/sfa/trust/gid.py
248 #/usr/local/gackscentral/bin/sfa/trust/rights.py
249 #/usr/local/gackscentral/bin/sfa/trust/trustedroot.py
250
251 #/usr/local/gackscentral/bin/sfa/util/__init__.py
252 #/usr/local/gackscentral/bin/sfa/util/client.py
253 #/usr/local/gackscentral/bin/sfa/util/faults.py
254 #/usr/local/gackscentral/bin/sfa/util/sfaticket.py
255 #/usr/local/gackscentral/bin/sfa/util/misc.py
256 #/usr/local/gackscentral/bin/sfa/util/namespace.py
257 #/usr/local/gackscentral/bin/sfa/util/parameter.py
258 #/usr/local/gackscentral/bin/sfa/util/record.py
259 #/usr/local/gackscentral/bin/sfa/util/report.py
260 #/usr/local/gackscentral/bin/sfa/util/rspec.py
261 #/usr/local/gackscentral/bin/sfa/util/xmlrpcprotocol.py
262