Merge lp:~jtv/maas/pkg-bug-1238376 into lp:~maas-committers/maas/trunk

Proposed by Jeroen T. Vermeulen
Status: Superseded
Proposed branch: lp:~jtv/maas/pkg-bug-1238376
Merge into: lp:~maas-committers/maas/trunk
Diff against target: 2963 lines (+2639/-0)
64 files modified
debian/changelog (+842/-0)
debian/compat (+1/-0)
debian/control (+283/-0)
debian/copyright (+25/-0)
debian/extras/20-maas.conf (+32/-0)
debian/extras/99-maas (+4/-0)
debian/extras/99-maas-sudoers (+3/-0)
debian/extras/isc-dhcp-server.override (+1/-0)
debian/extras/maas (+8/-0)
debian/extras/maas-cli (+2/-0)
debian/extras/maas-provision (+7/-0)
debian/extras/maas-region-celeryd (+50/-0)
debian/extras/maas_remote_syslog_compress (+2/-0)
debian/maas-cli.install (+2/-0)
debian/maas-cli.lintian-overrides (+1/-0)
debian/maas-cluster-controller.config (+36/-0)
debian/maas-cluster-controller.dirs (+1/-0)
debian/maas-cluster-controller.install (+32/-0)
debian/maas-cluster-controller.links (+1/-0)
debian/maas-cluster-controller.lintian-overrides (+2/-0)
debian/maas-cluster-controller.logrotate (+9/-0)
debian/maas-cluster-controller.maas-cluster-celery.upstart (+30/-0)
debian/maas-cluster-controller.maas-pserv.upstart (+31/-0)
debian/maas-cluster-controller.postinst (+149/-0)
debian/maas-cluster-controller.postrm (+38/-0)
debian/maas-cluster-controller.templates (+7/-0)
debian/maas-common.install (+2/-0)
debian/maas-common.postinst (+14/-0)
debian/maas-common.postrm (+14/-0)
debian/maas-dhcp.apparmor (+7/-0)
debian/maas-dhcp.install (+1/-0)
debian/maas-dhcp.maas-dhcp-server.upstart (+65/-0)
debian/maas-dhcp.postinst (+15/-0)
debian/maas-dhcp.postrm (+13/-0)
debian/maas-dns.dirs (+1/-0)
debian/maas-dns.postinst (+36/-0)
debian/maas-dns.postrm (+23/-0)
debian/maas-region-controller.apport (+37/-0)
debian/maas-region-controller.config (+45/-0)
debian/maas-region-controller.dirs (+2/-0)
debian/maas-region-controller.install (+37/-0)
debian/maas-region-controller.links (+2/-0)
debian/maas-region-controller.lintian-overrides (+6/-0)
debian/maas-region-controller.logrotate (+18/-0)
debian/maas-region-controller.maas-region-celery.upstart (+26/-0)
debian/maas-region-controller.maas-txlongpoll.upstart (+27/-0)
debian/maas-region-controller.postinst (+287/-0)
debian/maas-region-controller.postrm (+59/-0)
debian/maas-region-controller.prerm (+12/-0)
debian/maas-region-controller.templates (+22/-0)
debian/maintscript (+2/-0)
debian/patches/01-fix-database-settings.patch (+26/-0)
debian/patches/02-pserv-config.patch (+38/-0)
debian/patches/03-txlongpoll-config.patch (+39/-0)
debian/patches/series (+3/-0)
debian/po/POTFILES.in (+2/-0)
debian/po/templates.pot (+82/-0)
debian/python-django-maas.install (+2/-0)
debian/python-maas-client.install (+1/-0)
debian/python-maas-provisioningserver.install (+4/-0)
debian/python-maas-provisioningserver.lintian-overrides (+1/-0)
debian/rules (+65/-0)
debian/source/format (+1/-0)
debian/watch (+3/-0)
To merge this branch: bzr merge lp:~jtv/maas/pkg-bug-1238376
Reviewer Review Type Date Requested Status
MAAS Maintainers Pending
Review via email: mp+190658@code.launchpad.net

This proposal has been superseded by a proposal from 2013-10-11.

Commit message

Restore (a new incarnation of) obsolescent /etc/maas/import_ephemerals.

Description of the change

This is part of the fix for bug 1238376. It requires this change to the source tree: https://code.launchpad.net/~jtv/maas/bug-1238376/+merge/190656 (already landed as r1701).

Jeroen

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== added directory 'debian'
2=== added file 'debian/changelog'
3--- debian/changelog 1970-01-01 00:00:00 +0000
4+++ debian/changelog 2013-10-11 14:15:22 +0000
5@@ -0,0 +1,842 @@
6+maas (1.4+bzr1701+dfsg-0ubuntu2) UNRELEASED; urgency=low
7+
8+ * UNRELEASED
9+
10+ [ Jeroen Vermeulen ]
11+ * Keep legacy import_ephemerals config for now.
12+
13+ -- Andres Rodriguez <andreserl@ubuntu.com> Thu, 10 Oct 2013 17:07:51 -0400
14+
15+maas (1.4+bzr1693+dfsg-0ubuntu1) saucy; urgency=low
16+
17+ * New Upstream Release (LP: #1218526)
18+ - This new upstream release contains fixes and improvements of the
19+ features approved by the FFe above.
20+ - Fixes commissioning failure on Saucy with 'Failed Test' (LP: #1237364)
21+ - Fixes access of static images over http (LP: #1236544)
22+ * d/maas-cluster-controller.postinst: a2enmod version module (LP: #1236544)
23+ * d/control: Bump depends on python-django to 1.4. (LP: #1236572)
24+ * d/maas-dhcp.postinst: Fail gracefully if apparmor_parser fails, allowing
25+ to install maas-dhcp during an ISO install. (LP: #1236786)
26+
27+ -- Andres Rodriguez <andreserl@ubuntu.com> Fri, 04 Oct 2013 12:33:05 -0400
28+
29+maas (1.4+bzr1656+dfsg-0ubuntu2) saucy; urgency=low
30+
31+ * debian/control: Recommends on maas-dns instead of Depends for region
32+ because maas-dns needs the region installed first.
33+
34+ -- Andres Rodriguez <andreserl@ubuntu.com> Thu, 03 Oct 2013 10:36:20 -0400
35+
36+maas (1.4+bzr1656+dfsg-0ubuntu1) saucy; urgency=low
37+
38+ [ Andres Rodriguez ]
39+ * New upstream bugfix release.
40+ - Respect filters for ephemerals_script.py.
41+ * debian/control: Depends on ubuntu-cloudimage-keyring instead of
42+ ubuntu-cloud-keyring; depends on python-distro-info.
43+ * debian/control: Remove suggests on maas-dhcp and maas-dns as they are
44+ now dependencies.
45+
46+ [ Scott Moser ]
47+ * debian/control: Bump depends on isc-dhcp-server to 4.2.4
48+ * debian/maas-dhcp.maas-dhcp-server.upstart: Change ownership of leases
49+ file to root:root, and run the daemon as dhcpd:dhcpd.
50+
51+ -- Andres Rodriguez <andreserl@ubuntu.com> Tue, 01 Oct 2013 15:26:34 -0400
52+
53+maas (1.4+bzr1655+dfsg-0ubuntu1) saucy; urgency=low
54+
55+ * New Upstream release. (LP: #1218526)
56+ * debian/control:
57+ - Depends on python-djorm-ext-pgarray, python-curtin,
58+ python-simplestreams, ubuntu-cloud-keyring.
59+ - Depends on maas-dns, maas-dhcp to get them seeded and
60+ into main (LP: #1227353)
61+
62+ -- Andres Rodriguez <andreserl@ubuntu.com> Wed, 28 Aug 2013 11:17:44 -0400
63+
64+maas (1.4+bzr1551+dfsg-0ubuntu1) saucy; urgency=low
65+
66+ * New upstream release
67+
68+ -- Andres Rodriguez <andreserl@ubuntu.com> Thu, 15 Aug 2013 16:20:41 -0400
69+
70+maas (1.4+bzr1548+dfsg-0ubuntu1) saucy; urgency=low
71+
72+ * New upstream release
73+
74+ -- Andres Rodriguez <andreserl@ubuntu.com> Thu, 18 Jul 2013 10:15:10 -0400
75+
76+maas (1.4+bzr1539+dfsg-0ubuntu1) saucy; urgency=low
77+
78+ * New upstream release
79+ * Symlink apache2 config into /etc/apache2/conf-enabled/ instead of
80+ /etc/apache2/conf.d as apache2.4 no longer supports the latter.
81+ - debian/maas-cluster-controller.{postinst,postrm}
82+ - debian/maas-region-controller.{postinst,postrm}
83+ * debian/control: Bump Standards-Version to 3.9.4.
84+ * debian/maas-cluster-controller.lintian-overrides: Remove unneeded
85+ override and add a new one.
86+ * debian/maas-region-controller.lintian-overrides: Add extra overrides.
87+
88+ -- Andres Rodriguez <andreserl@ubuntu.com> Wed, 03 Jul 2013 17:11:02 -0400
89+
90+maas (1.4+bzr1538+dfsg-0ubuntu1) saucy; urgency=low
91+
92+ * New upstream release
93+ * debian/patches/04-setup-dont-user-list-snippets.patch: Drop. Merged
94+ Upstream.
95+
96+ -- Andres Rodriguez <andreserl@ubuntu.com> Thu, 13 Jun 2013 20:06:35 -0400
97+
98+maas (1.4+bzr1527+dfsg-0ubuntu1) saucy; urgency=low
99+
100+ * debian/patches/04-setup-dont-user-list-snippets.patch: Drop importing
101+ maasserver modules to list snippets in favor to using glob. Otherwise
102+ we would have to add various non necessary Build-Dependencies.
103+
104+ [ Jeroen Vermeulen ]
105+ * Install templates into /etc/maas/templates/.
106+
107+ -- Andres Rodriguez <andreserl@ubuntu.com> Mon, 03 Jun 2013 17:59:31 -0400
108+
109+maas (1.4+bzr1505+dfsg-0ubuntu1) saucy; urgency=low
110+
111+ * New upstream release
112+
113+ [ Steve Langasek ]
114+ * Add missing dependency on iproute to maas-region-controller, for use of
115+ /sbin/ip in postinst.
116+
117+ [ Julian Edwards ]
118+ * debian/maas-dhcp.maas-dhcp-server.upstart:
119+ - Detect 12.04 as the host OS and install with correct permissions. This
120+ allows the same packaging to be used in the 12.04 backport.
121+
122+ [ Andres Rodriguez ]
123+ * Update packaging to support FPI:
124+ - debian/control: Depends on apache2 for maas-cluster-controller.
125+ - debian/maas-cluster-controller.install: Install http config file.
126+ - debian/maas-cluster-controller.{postinst,postrm}: Handle symlink creation
127+ and deletion.
128+ * debian/maas-region-controller.install: Install preseeds in
129+ etc/maas/preseeds. (LP: #1073463)
130+
131+ [ Jeroen Vermeulen ]
132+ * In the source tree, /etc/maas/pserv.yaml has moved from etc/ to etc/maas/.
133+ * Install templates into /etc/maas/templates/.
134+
135+ -- Andres Rodriguez <andreserl@ubuntu.com> Mon, 03 Jun 2013 16:53:14 -0400
136+
137+maas (1.3+bzr1455+dfsg-0ubuntu1) raring; urgency=low
138+
139+ * New upstream bugfix release.
140+ - Fixes and returns the 'resource_url' with the 'canonical' url for
141+ a file that is fetched using the API (LP: #1154142)
142+
143+ [ Andres Rodriguez ]
144+ * debian/control:
145+ - Change Conflicts/Replaces for Breaks/Replaces.
146+ - Conflicts on tftpd-hpa and dnsmasq.
147+ - Do not pre-depends, but Depends on ${misc:Depends} for 'maas'.
148+
149+ [ Steve Langasek ]
150+ * postinst scripts are never called with 'reconfigure' as the script
151+ argument. Remove references to this (mythical) invocation.
152+ * always call 'set -e' from maintainer scripts instead of passing 'sh -e'
153+ as the interpreter, so that scripts will behave correctly when run via
154+ 'sh -x'.
155+ * invoke-rc.d is never allowed to not exist - simplify scripts (and make
156+ them better policy-compliant) by invoking unconditionally. (The only
157+ possible exception is in the postrm, where it's *theoretically* possible
158+ for invoke-rc.d to be missing if the user has completely stripped
159+ down their system; that's a fairly unreasonable corner case, but we
160+ might as well be correct if it ever happens.)
161+ * db_get+db_set is a no-op; don't call db_set to push back a value we just
162+ got from db_get.
163+ * Omit superfluous calls to 'exit 0' at the end of each script.
164+ * Remove maas-cluster-controller prerm script, which called debconf for no
165+ reason.
166+ * Don't invoke debconf in the postrm script either, debhelper already does
167+ this for us.
168+ * Other miscellaneous maintainer script fixes
169+ * debian/maas-common.postinst: call adduser and addgroup unconditionally;
170+ the tools are already designed to DTRT, we don't need to check for the
171+ user/group existence before calling them nor should we worry about
172+ calling them only once on first install.
173+ * debian/maas-common.postrm: delete the maas group, not just the user,
174+ as the comment in the code implies we should do.
175+
176+ -- Andres Rodriguez <andreserl@ubuntu.com> Tue, 19 Mar 2013 15:38:22 -0400
177+
178+maas (1.3+bzr1452+dfsg-0ubuntu1) raring; urgency=low
179+
180+ * New upstream release.
181+ - MAAS file storage mechanism is shifting from a single shared
182+ namespace to a per-user namespace. Operators of the majority
183+ of MAAS systems will not notice any change. However, operators
184+ of the most complex installations may find that a new
185+ "shared-environment" user is created, and that some resources
186+ are reassigned to it, such as API credentials and SSH public
187+ keys. This provides a transitional environment that mimics the
188+ behaviour of a shared namespace.
189+
190+ [ Raphaël Badin ]
191+ * debian/control: maas-region-controller depends on bind9utils.
192+ (LP: #1103195)
193+ * debian/maas-dns.postinst: Call write_dns_config.
194+ (LP: #1085865).
195+ * debian/maas-cluster-controller.postinst: Fix the name of the config
196+ file (/etc/maas/pserv.yaml and not /etc/maas/pserv.conf)
197+ (LP: #1083542).
198+ * debian/extras/99-maas-sudoers: Add 'SETENV:' to sudo rule
199+ to allow preserving the environment when running
200+ /usr/sbin/maas-import-pxe-files via sudo.
201+ * debian/maas-dns.postinst: fix permissions and group ownership of
202+ file /etc/bind/maas/named.conf.rndc.maas. (LP: #1066935)
203+ * debian/control: Remove the dependency of maas-cluster-controller
204+ on rabbitmq-server. (LP: #1072744)
205+ * debian/extras/99-maas-sudoers: Add sudo rule for script
206+ /usr/sbin/maas-import-pxe-files.
207+ * debian/maas-cluster-controller.install: Removed commissioning-user-data
208+ script.
209+
210+ [ Julian Edwards ]
211+ * debian/maas-region-controller.install: Remove installation of maas-gc; it
212+ is no longer required as upstream no longer stores files in the filesystem.
213+ (LP: #1069734)
214+ * debian/maas-cluster-controller.postinst: Ensure that /etc/maas/pserv.yaml
215+ is updated when reconfiguring. (LP: #1081212)
216+
217+ [ Jeroen Vermeulen ]
218+ * debian/maas-cluster-controller.install: Install import scripts.
219+ * debian/maas-cluster-controller.postinst: Configure tgt (the iSCSI server)
220+ so the import script can install files to it.
221+ * debian/maas-cluster-controller.postrm: Clean up tgt config.
222+ * debian/maas-region-controller.install: Move import scripts out to the
223+ cluster controller, and drop the maas-import-isos compatibility script.
224+ * debian/maas-region-controller.postinst: Remove tgt config.
225+ * debian/maas-region-controller.postrm: Remove tgt config cleanup.
226+ * Bump code revision to include latest user_data.template fixes.
227+
228+ [ Gavin Panella ]
229+ * debian/extras/99-maas: squashfs image download is no longer needed.
230+ * debian/maas-cluster-controller.install: maas-import-squashfs and its
231+ configuration file are no longer part of upstream.
232+ * debian/maas-cluster-controller.install: The maas-import-pxe-files cron
233+ task is no longer used.
234+ * debian/maas-cluster-controller.postinst: Remove leading comment
235+ markers from the 'generator' line in pserv.yaml.
236+
237+ [ Andres Rodriguez ]
238+ * debian/control:
239+ - maas-cluster-controller Conflicts with tftpd-hpa (LP: #1076028)
240+ - maas-dns: Conflicts with dnsmasq
241+ - maas-cluster-controller Conflicts/Replaces maas-region-controller as
242+ import scripts are no longer shipped in the region.
243+ - debian/control: Depends on distro-info for maas-cluster-controller
244+ instead of maas-region-controller (LP: #1103194)
245+ * debian/maas-cluster-controller.config: If URL has been detected,
246+ add /MAAS if it doesn't contain it. This helps upgrades from versions
247+ where DEFAULT_MAAS_URL didn't use /MAAS.
248+
249+ -- Andres Rodriguez <andreserl@ubuntu.com> Mon, 04 Mar 2013 11:49:44 -0500
250+
251+maas (0.1+bzr1269+dfsg-0ubuntu1) quantal-proposed; urgency=low
252+
253+ * New upstream bugfix release
254+ - Fixes commissioning failing to set memory attribute. (LP: #1064638)
255+ - Fixes node listing by adding pagination (LP: #1064672)
256+ - Changes default bind rndc key which breaks initscripts (LP: #1066938)
257+ - Fixes invalid DNS config once node is enlisted (LP: #1066958)
258+ - Reference documentation link to correct URL (LP: #1067261)
259+
260+ [ Andres Rodriguez ]
261+ * debian/rules: Change upstream branch.
262+
263+ [ Gavin Panella ]
264+ * debian/maas-dns.postinst: Remove MAAS-related include lines from named's
265+ config before adding a new one (LP: #1066929)
266+
267+ [ Raphael Badin ]
268+ * debian/extras/maas-region-celeryd: Remove whitespace that affects DNS
269+ rabbitmq queue. (LP: #1067929)
270+
271+ -- Andres Rodriguez <andreserl@ubuntu.com> Tue, 16 Oct 2012 10:31:37 -0400
272+
273+maas (0.1+bzr1264+dfsg-0ubuntu2) quantal; urgency=low
274+
275+ * Fix MAAS not working after CD/preseed install (LP: #1065763)
276+ - debian/extras/maas-region-celeryd: Add wrapper to run celery from
277+ the upstart job.
278+ - debian/extras/maas-region-controller.maas-region-celery.upstart: Create
279+ rabbitmq user if it does not exists.
280+ * debian/control: Remove unneeded deps on python-txtftp for some binary pkgs.
281+ * debian/maas-region-controller.postinst: Minor fix referencing variable.
282+
283+ -- Andres Rodriguez <andreserl@ubuntu.com> Thu, 11 Oct 2012 17:38:08 -0400
284+
285+maas (0.1+bzr1264+dfsg-0ubuntu1) quantal; urgency=low
286+
287+ * New upstream release.
288+
289+ [ Raphaël Badin ]
290+ * debian/maas-region-controller.postinst: Enable proxy_http module.
291+ * debian/maas-cluster-controller.postinst: Create /var/lib/maas. (LP: #1065062)
292+
293+ [ Andres Rodriguez ]
294+ * Install maas-provision with python-maas-provisioningserver (LP: #1065171):
295+ - debian/python-maas-provisioningserver.install: Install
296+ - debian/control: Add Conflicts/Replaces with maas-cluster-controller
297+ to handle upgrades.
298+ * debian/patches/04-fix-ipmi-enlistment.patch: Drop. Merged Upstream.
299+ * debian/control: Depends on maas-region-controller for maas-dns.
300+ * debian/maas-region-controller.postinst: Set the correct host for
301+ BROKER_URL (LP: #1065080)
302+ * Handle creation of user/group in maas-common.
303+ * debian/maas-region-controller.config: Always source dbconfig scripts.
304+
305+ -- Andres Rodriguez <andreserl@ubuntu.com> Wed, 10 Oct 2012 11:17:21 -0400
306+
307+maas (0.1+bzr1243+dfsg-0ubuntu3) quantal; urgency=low
308+
309+ * 04-fix-ipmi-enlistment.patch: retry maas-enlist without power parameters
310+ on failure. This allows enlistment to continue working with Precise
311+ ephemeral images before the Precise SRU for maas-enlist lands.
312+ (LP: #1064922).
313+
314+ -- Robie Basak <robie.basak@canonical.com> Wed, 10 Oct 2012 13:29:16 +0000
315+
316+maas (0.1+bzr1243+dfsg-0ubuntu2) quantal; urgency=low
317+
318+ * debian/patches/99-ipmi-user-too-long.patch: Fix username too long for
319+ IPMI user created on enlistment (LP: #1064832)
320+
321+ -- Andres Rodriguez <andreserl@ubuntu.com> Wed, 10 Oct 2012 01:00:29 -0400
322+
323+maas (0.1+bzr1243+dfsg-0ubuntu1) quantal; urgency=low
324+
325+ * New upstream release. (LP: #1064596)
326+ * debian/patches/99-temporary-fix-constraints.patch: Dropped.
327+ * debian/control:
328+ - ${python:Depends} for maas-common.
329+ - Add missing Depends for python-maas-provisioningserver (LP: #1064542)
330+ * debian/maas-cluster-controller.postinst: Create /var/log/maas if it
331+ doesn't exist (LP: #1064539)
332+
333+ -- Andres Rodriguez <andreserl@ubuntu.com> Mon, 08 Oct 2012 17:02:56 -0400
334+
335+maas (0.1+bzr1223+dfsg-0ubuntu1) quantal; urgency=low
336+
337+ * New upstream release. (LP: #1062518)
338+
339+ [ Julian Edwards ]
340+ * Split packaging of 'maas' into maas-{region,cluster}-controller
341+ - debian/control: Update accordingly.
342+ - debian/*.install: Move files accordingly
343+ - debian/*.{postinst,postrm,preinst}: Move files accordingly.
344+ * Ensure isc-dhcp-server is disabled when installing maas-dhcp.
345+ * Ensure maas-dns creates the maas user before trying to chown files.
346+ * Make maas-cluster-controller autoconfigure itself when upgrading from the
347+ old maas package. (LP: #1059416)
348+ * Add missing prerm file for maas-cluster-controller so that .pyc files
349+ are cleaned up. (LP: #1059973)
350+
351+ [ Raphaël Badin ]
352+ * Install maas_local_celeryconfig.py in /etc/maas and symlink to
353+ /usr/share/maas.
354+ * debian/maas.postinst: Create rabbitmq celery user/vhost.
355+ * debian/maas.postinst: Update BROKER_URL in maas_local_celeryconfig.py.
356+ * Use maas_local_celeryconfig_cluster.py as the local celery
357+ configuration file for the cluster worker.
358+ * debian/maas-region-controller.maas-region-celery.upstart: Add region
359+ worker upstart script.
360+ * Rename cluster worker upstart script into
361+ maas-cluster-controller.maas-clluster-celery.upstart.
362+ * maas-cluster-controller.maas-celery.upstart: use "celeryconfig_cluster"
363+ as the Celery config module.
364+ * debian/maas-common.install: Install celeryconfig_common.py.
365+ * debian/maas-cluster-controller.install: Install celeryconfig_cluster.py.
366+ * debian/maas-region-controller.install: Install celeryconfig.py.
367+ * Split celery config into cluster and region configs.
368+ * Add region celeryd upstart config.
369+ * Define CELERY_CONFIG_MODULE in
370+ maas-cluster-controller.maas-cluster-celery.upstart
371+
372+ [ Jeroen Vermeulen ]
373+ * Make maas_local_celery_config.py non-world readable.
374+ * Make maas_local_celeryconfig_cluster.py non-world readable.
375+ * Set root:maas ownership of local cluster config only *after*
376+ the maas user/group have been created
377+
378+ [ Andres Rodriguez ]
379+ * debian/maas.postinst:
380+ - Always restart apache2.
381+ - Handle upgrades for new upstream release.
382+ - Handle upgrades for celery rabbitmq worker.
383+ * Add binary package to install client tool.
384+ - debian/extras/maas-cli: Add binary.
385+ - debian/maas-cli.install: Add. Install maascli and apiclient.
386+ - debian/control: Add binary package.
387+ * debian/control:
388+ - Depends on freeipmi-tools instead of ipmitool.
389+ - Conflicts/Replaces on maas for python-maas-client.
390+ - Depends on python-netifaces, python-lxml.
391+ * Add python-maas-client binary package:
392+ - debian/python-maas-client.install: Add. Install 'apiclient' python module.
393+ - debian/control: Add package. python-django-maas and maas-cli now
394+ Depend on it.
395+ * debian/rules: Install maas-dhcp-server upstart job.
396+ * debian/maas.postrm: Remove celery worker rabbitmq user and host.
397+ * debian/extras/99-maas-sudoers: Add for maas-dhcp-server upstart job
398+ instead of isc-dhcp-server (LP: #1055951)
399+ * debian/maas-region-controller.postinst: Cleanup upgrade rules.
400+ * debian/maas-cluster-controller.postinst: Fix 'local' usage.
401+ * debian/maas-common.install: Install celeryconfig in appropriate location.
402+ * debian/maas-cluster-controller.postrm: Add and delete maas user.
403+ * debian/maas-dhcp.postinst: Stop isc-dhcp-server not isc_dhcp_server.
404+ * debian/maas-region-controller.postinst:
405+ - Always update passwords on upgrade. No longer check versioning. (LP: #1060094).
406+ - Add MAAS server to allowed mirror in squid-deb-proxy
407+ - Source dbconfig conf file for maas-region-controller on upgrade because
408+ it writes a new config file and no longer preservers the previous password.
409+ * debian/maas-cluster-controller.maas-cluster-celery.upstart: Remove set{uid/gid}.
410+ * debian/maas-region-controller.install: Install maas-import-squashfs
411+ * Handle removal of non existant files (LP: #1059556):
412+ - debian/maintscript: Added to handle removal of conffiles.
413+ - debian/control: Add Pre-depends and bump debhelper version.
414+ * update po files for the templates.
415+ * debian/extras/99-maas: Install in usr/share/maas/conf and symlink to the
416+ appropriate etc dir.
417+ * debian/maas-cluster-controller.config: Source debconf at the beginning of the
418+ script. (LP: #1063857)
419+ * debian/patches/99-temporary-fix-constraints.patch: Fix constraints maaping
420+ when deploying with juju. Temporary until it gets merged upstream
421+
422+ [ Robie Basak ]
423+ * Add maas-cluster-controller dependency on uuid-runtime, needed for uuidgen
424+ by postinst.
425+
426+ [ Scott Moser ]
427+ * debian/maas-dhcp.{install,apparmor,postrm} install apparmor profile into
428+ /etc/apparmor.d/dhcpd.d (LP: #1049177), and update apparmor profile for
429+ /usr/sbin/dhcpd on install/remove
430+ * get the ip address for the dhcp server in config
431+
432+ [ Diogo Matsubara ]
433+ * Add initial tests to be run by autotests:
434+ - debian/control: XS-Testsuite: autopkgtest
435+ - debian/tests/control: Add
436+ - debian/tests/maas-package-test: Add
437+ - tests/maas-integration.py: Add
438+
439+ -- Andres Rodriguez <andreserl@ubuntu.com> Mon, 08 Oct 2012 13:10:23 -0400
440+
441+maas (0.1+bzr971+dfsg-0ubuntu2) quantal; urgency=low
442+
443+ * debian/extras/99-maas-sudoers: Add missing rule for
444+ maas-provision. (LP: #1046397)
445+
446+ -- Andres Rodriguez <andreserl@ubuntu.com> Wed, 05 Sep 2012 12:36:58 -0400
447+
448+maas (0.1+bzr971+dfsg-0ubuntu1) quantal; urgency=low
449+
450+ * New upstream release (LP: #1044367)
451+
452+ [ Julian Edwards ]
453+ * Fix 02-pserv-config.patch to handle new default tftp directory
454+
455+ [ Andres Rodriguez ]
456+ * debian/maas.postinst:
457+ - include '/MAAS' for DEFAULT_MAAS_URL.(LP: #1033956)
458+ - Update bzr version to safely upgrade.
459+ * Add maas-dns package that configures DNS in MAAS (LP: #1030860)
460+ * Remove cobbler related bits
461+ - debian/maas.postinst: Drop cobbler configuration
462+ - debian/maas.install: Drop installation of snippets/preseeds.
463+ - debian/control:
464+ + Drop Depends on maas-provision. (LP: #975473)
465+ + Depends on bind9utils.
466+ + Depends on python-lockfile (LP: #1037400)
467+ Add necessary Conflicts/Replaces. Add conflicts to tftpd-hpa and dnsmasq.
468+ Depends on isc-dhcp-server for maas-dhcp, and syslinux-common.
469+ - debian/extras/maas-provision: Add missing "$@" (LP: #1040462)
470+ - debian/patches:
471+ + 02-pserv-config.patch: Updated. Do not patch cobbler related bits.
472+ patch tftp config to default.
473+ * maas-dhcp: Re-add to handle initial configuration of MAAS DHCP server.
474+ * Allow restart of 'isc-dhcp-server' by adding a sudoers file:
475+ - debian/extras/99-maas-sudoers: Added.
476+ - debian/maas.install: Install 99-maas-sudoers
477+ * Minor improvements on dbconfig-common handling:
478+ - debian/maas.config: Only call dbc_go when scripts present.
479+ - debian/maas.postrm: Only call dbc_go when config file exists.
480+ * debian/maas.maas-celery.upstart: Enable Beat and set scheduler db file.
481+ * debian/maas-dns.postinst: Set correct permissions. (LP: #1042868)
482+ * debian/maas-dhcp.config:
483+ - Ask whether we want to enable DHCP (LP: #1044229)
484+ - Add debconf question for network interfaces
485+ * debian/maas.prerm: Stop services before removing database (LP: #1044559)
486+
487+ -- Andres Rodriguez <andreserl@ubuntu.com> Thu, 02 Aug 2012 09:01:43 -0400
488+
489+maas (0.1+bzr777+dfsg-0ubuntu1) quantal-proposed; urgency=low
490+
491+ * New upstream release
492+ * Only run 'maas' command as root. (LP: #974046)
493+ - debian/extras/maas: Check id.
494+ - debian/maas.install: Install in 'sbin'.
495+ * debian/maas.postinst:
496+ - restart apache2 after everything gets processed.
497+ - Update version to handle upgrades.
498+ * debian/extras/maas-provision: Add wrapper to access 'maasprovisiong'
499+ command line.
500+ * debian/patches/99_temporary_fix_path.patch: Dropped. No longer needed.
501+
502+ -- Andres Rodriguez <andreserl@ubuntu.com> Tue, 17 Jul 2012 08:28:36 -0400
503+
504+maas (0.1+bzr745+dfsg-0ubuntu2) quantal; urgency=low
505+
506+ * debian/control: Build-Dep on python-django instead of
507+ python-django-configglue
508+
509+ -- Andres Rodriguez <andreserl@ubuntu.com> Tue, 17 Jul 2012 08:24:25 -0400
510+
511+maas (0.1+bzr745+dfsg-0ubuntu1) quantal; urgency=low
512+
513+ * New Upstream Release
514+ * debian/patches:
515+ - 99_power_fixes.patch: Dropped. Merged Upstream.
516+ - 99_enums_js.patch: Dropped. No longer needed.
517+ * Automatically build enums.js:
518+ - debian/control: Build-Depends on python-django-configglue
519+ - debian/rules: Build and install enums.js.
520+ * debian/maas.postinst: Update version to handle upgrades
521+
522+ -- Andres Rodriguez <andreserl@ubuntu.com> Thu, 12 Jul 2012 16:34:11 -0400
523+
524+maas (0.1+bzr740+dfsg-0ubuntu1) quantal; urgency=low
525+
526+ * New upstream release
527+ * debian/control: Depends on python-txtftp.
528+ * debian/rules: Do not ship python-tx-tftp.
529+ * debian/maas.postinst: Update version to upgrade successfully.
530+ * debian/patches:
531+ - 02-pserv-config.patch: Refreshed.
532+ - 99_enums_js.patch: Updated.
533+ - 99_power_fixes.patch: Added temporarily to enable IPMI
534+ - 99_temporary_fix_path.patch: Added temporarily to not fail when
535+ importing celeryconfig
536+
537+ -- Andres Rodriguez <andreserl@ubuntu.com> Tue, 03 Jul 2012 17:54:49 -0400
538+
539+maas (0.1+bzr709+dfsg-0ubuntu1) quantal; urgency=low
540+
541+ * New Upstream release
542+ * debian/control:
543+ - Depends on python-celery, python-tempita, libjs-yui3-{full,min},
544+ libjs-raphael
545+ * debian/maas.install:
546+ - Install apiclient, celeryconfig.py, maas-import-pxe-files, preseeds_v2.
547+ - Update to install various files from chroot, rather tha manually copy
548+ them from the source.
549+ * debian/maas.links: symlink celeryconfig.py
550+ * debian/maas.maas-celery.upstart: Add job.
551+ * debian/rules:
552+ - Install celery upstart job.
553+ - Do not install jslibs as packages are now used.
554+ - Drop copying of maas_local_settings_sample.py as source now ships
555+ a maas_local_settings.py
556+ * debian/patches:
557+ - 04-maas-http-fix.patch: Drop. Merged upstream.
558+ - 01-fix-database-settings.patch: Refreshed.
559+ - 99_enums_js.patch: Added until creation of enum.js / build process
560+ is fixed.
561+ * debian/maas.postinst: Update bzr version to correctly handle upgrades.
562+
563+ -- Andres Rodriguez <andreserl@ubuntu.com> Tue, 03 Jul 2012 17:42:37 -0400
564+
565+maas (0.1+bzr482+dfsg-0ubuntu1) precise; urgency=low
566+
567+ * New upstream release (Fixes LP: #981103)
568+ * debian/maas.postinst:
569+ - Make sure rabbitmq and postgresql are started on upgrade (LP: #981282)
570+ - Handle upgrades from any lower than 0.1+bzr462+dfsg-0ubuntu1 to
571+ correctly re-generate passwords, and not have db sync/migrate issues
572+ as config has changed upstream.
573+ - Correctly set Passwords for PSERV, otherwise it won't set new passwords.
574+ * Allow MAAS_DEFAULT_URL reconfiguration. (LP: #980970)
575+ - debian/maas.config: Add reconfigure validation to correctly allow it,
576+ and ask a question.
577+ - debian/maas.postinst: Reconfigure DEFAULT_MAAS_URL as well as cobbler
578+ server and next_server for PXE/Provisioning.
579+ - debian/maas.templates: Add debconf question and update info.
580+ * Do not lose MAAS_DEFAULT_URL settings on upgrade (LP: #984309)
581+ * debian/maas.postinst:
582+ - Set cobbler password in between quotes (LP: #984427)
583+ - Do not change permissions to maas.log (LP: #980915)
584+ * no longer use maas-cloudimg2ephemeral, but rather use premade images
585+ at http://maas.ubuntu.com
586+
587+ -- Andres Rodriguez <andreserl@ubuntu.com> Tue, 17 Apr 2012 23:44:46 -0700
588+
589+maas (0.1+bzr462+dfsg-0ubuntu1) precise; urgency=low
590+
591+ * New upstream release (LP: #980240)
592+
593+ [ Scott Moser ]
594+ * add dependency on distro-info (LP: #949442)
595+ * debian/control: add dependency on tgt for ephemeral iscsi environment
596+
597+ [ Andres Rodriguez ]
598+ * Make package lintian clean:
599+ - maas{-dhcp}.lintian-overrides: Add to make lintian clean.
600+ - debian/control: Add missing dependencies; correct section and desc.
601+ - debian/maas.postinst: Do not use absolute path for rabbitmqctl.
602+ - debian/patches: Add headers to all patches.
603+ * debian/maas-dhcp.postrm: Added to disable dnsmasq in cobbler on removal.
604+ * debian/maas.config: Do not set a password with pwgen as it is not an
605+ essential package; allow dbconfig-common to create a password instead by
606+ creating an empty question. (LP: #977475)
607+ * Run MAAS, pserv, txlongpoll as non-root user. (LP: #975436)
608+ - debian/maas.postinst: Create user/group; set correct permissions for
609+ directories.
610+ - debian/maas.postrm: Remove user/group; restart apache2.
611+ - debian/maas.maas-{pserv,txlongpoll}.upstart: Update to run as non-root
612+ 'maas' user.
613+ * debian/patches/01-fix-database-settings.patch: Remove adding of PSERV_URL.
614+ * debian/maas.postinst:
615+ - Handle config file upgrade from versions lower than 0.1+bzr445+dfsg-0ubuntu1,
616+ by creating new passwords and updating accordingly
617+ - use local variables in functions.
618+ - Handle maas tgt configuration for upgrades from 0.1+bzr459+dfsg-0ubuntu1.
619+ * debian/extras/99-maas: Add squid-deb-proxy file to enable PPAs. (LP: #979383)
620+ * debian/maas.install: Install missing commissioning-user-data script.
621+
622+ [ Dave Walker (Daviey) ]
623+ * debian/patches/02-pserv-config.patch: Refreshed to apply to updated config.
624+
625+ [ Gavin Panella ]
626+ * debian/maas.postinst: Update pserv.yaml and maas_local_settings.py to use
627+ password.
628+
629+ -- Andres Rodriguez <andreserl@ubuntu.com> Thu, 12 Apr 2012 16:37:53 -0400
630+
631+maas (0.1+bzr415+dfsg-0ubuntu2) precise; urgency=low
632+
633+ * debian/maas-dhcp.{config,postinst}:
634+ - Fix not setting new values on fresh install. (LP: #975321)
635+ - Fix unsetting domain, otherwise, even if disabled, it will always be set.
636+ * debian/control: Depends on maas for maas-dhcp.
637+
638+ -- Andres Rodriguez <andreserl@ubuntu.com> Fri, 06 Apr 2012 15:30:44 -0400
639+
640+maas (0.1+bzr415+dfsg-0ubuntu1) precise; urgency=low
641+
642+ * debian/control: Update package descriptions; Suggests maas-dhcp for maas
643+ and add a maas-dhcp binary.
644+ * Add maas-dhcp package to configure a DHCP server.
645+ - debian/maas-dhcp.config: Add to ask debconf questions about range,
646+ gateway, and domain.
647+ - debian/maas-dhcp.postinst: Handle update of config values.
648+ - debian/maas-dhcp.templates: Debconf questions.
649+ * debian/po: Update for templates.
650+ * Add message telling MAAS URL after installation.
651+ - debian/maas.templates: Add message.
652+ - debian/maas.postinst: Display message.
653+ * debian/maas.config: Hide dbconfig-install question.
654+
655+ -- Andres Rodriguez <andreserl@ubuntu.com> Wed, 04 Apr 2012 14:47:13 -0400
656+
657+maas (0.1+bzr400+dfsg-0ubuntu1) precise; urgency=low
658+
659+ * debian/patches/{02-pserv-config,03-txlongpoll-config}.patch: Refreshed.
660+ * debian/maas.install: Install maas-gc cronjob.
661+ * Add apport hook.
662+ - debian/maas.apport: Add hook.
663+ - debian/rules: Install with apport.
664+ * debian/maas.logrotate: Add logrotate for txlongpoll and pserv logs.
665+ * Create 'var/lib/media/maas/storage' on postinst to have right permissions.
666+ - debian/maas.dirs: Drop dir creation.
667+ - debian/maas.postinst: Create dir with correct permissions.
668+ - debian/maas.postrm: Remove dir on purge.
669+
670+ -- Andres Rodriguez <andreserl@ubuntu.com> Tue, 03 Apr 2012 14:50:34 -0400
671+
672+maas (0.1+bzr378+dfsg-0ubuntu1) precise; urgency=low
673+
674+ * maas.dirs: Create var/lib/maas/media/storage for juju storage.
675+ * maas.postinst:
676+ - Give correct permissions to above dir.
677+ - stop apache2 before db upgrade, and restart after.
678+
679+ -- Andres Rodriguez <andreserl@ubuntu.com> Thu, 29 Mar 2012 19:28:13 -0400
680+
681+maas (0.1+bzr363+dfsg-0ubuntu1) precise; urgency=low
682+
683+ [ Dave Walker (Daviey) ]
684+ * debian/control: Add openssh-server as a Recommends, and wrap-and-sort.
685+
686+ [ Andres Rodriguez ]
687+ * debian/maas.postinst:
688+ - Do not start apache with apache2ctl. Use invoke-rc.d instead to not
689+ fail in the installer.
690+ - For start of postgresql before creating the DB, otherwise it will
691+ fail in the installer.
692+ - Add check of invoke-rc.d for syslog.
693+ - Add check of invoke-rc.d for rabbitmq-server; Add check for rabbitmqctl
694+ - Add db_stop, in case invoke-rc.d fails.
695+ * debian/control: Tight python-django-maas dependency.
696+ * debian/postrm: Add check for rabbitmqctl.
697+ * debian/maas.maas-txlongpoll.upstart: Create rabbitmq longpoll user/vhost
698+ and set permissions if they don't exist. Start on rabbitmq-server-running.
699+
700+ -- Andres Rodriguez <andreserl@ubuntu.com> Tue, 27 Mar 2012 14:49:56 -0400
701+
702+maas (0.1+bzr338+dfsg-0ubuntu1) precise; urgency=low
703+
704+ [ Dave Walker (Daviey) ]
705+ * d/patches/03-txlongpoll-config.patch: Resolve typo error from prior patch.
706+ - LP: #961031
707+
708+ [ Andres Rodriguez ]
709+ * debian/maas.config: Don't allow reconfigure.
710+ * debian/maas.postinst: Don't allow reconfigure. Run sync/migrate db on
711+ all upgrades.
712+
713+ [ Scott Moser ]
714+ * add rsylog config for logging node boots (LP: 960149)
715+
716+ -- Andres Rodriguez <andreserl@ubuntu.com> Thu, 22 Mar 2012 10:56:58 -0400
717+
718+maas (0.1+bzr315+dfsg-0ubuntu1) precise; urgency=low
719+
720+ * New upstream snapshot.
721+
722+ [ Dave Walker ]
723+ * debian/maas.postinst: Do not import ISO's at install time.
724+ * debian/control:
725+ - Drop run-one, it's not a requirement and currently in universe.
726+ - Drop python-setproctitle, no longer required.
727+
728+ [ Andres Rodriguez ]
729+ * debian/control: Depends on python-avahi, python-dbus, and avahi-daemon.
730+ * debian/maas.postinst:
731+ - Only syncdb if dbconfig db creation was selected.
732+ - Set rabbitmq/longpoll settings
733+ * debian/patches/03-txlongpoll-config.patch: Updated broker settings for
734+ rabbitmq.
735+
736+ -- Andres Rodriguez <andreserl@ubuntu.com> Tue, 20 Mar 2012 20:10:58 -0400
737+
738+maas (0.1+bzr300+dfsg-0ubuntu1) precise; urgency=low
739+
740+ * debian/patches:
741+ - 01-fix-database-settings.patch: Update PSERV_URL port.
742+ - 02-pserv-config.patch: Update, and set 'maas' as username.
743+ - 03-longpoll-config.patch: Update.
744+ * debian/maas.install: Install preseeds and snippets.
745+ * debian/maas.postinst:
746+ - Set password for 'maas' cobbler username (in pserv and cobbler).
747+ - Set DEFAULT_MAAS_URL to IP of interface with default gateway.
748+
749+ -- Andres Rodriguez <andreserl@ubuntu.com> Fri, 16 Mar 2012 14:59:16 -0400
750+
751+maas (0.1+bzr295+dfsg-0ubuntu2) precise; urgency=low
752+
753+ * debian/patches:
754+ - 01-fix-database-settings.patch: Update to set PSERV_URL.
755+ - 02-pserv-config.patch: Set port to 8001.
756+ * debian/maas.postinst: Run maas-import-isos on install.
757+ * debian/control: Depends on rabbitmq-server.
758+
759+ -- Andres Rodriguez <andreserl@ubuntu.com> Thu, 15 Mar 2012 18:14:08 -0400
760+
761+maas (0.1+bzr295+dfsg-0ubuntu1) precise; urgency=low
762+
763+ * debian/maas.upstart: Specify pidfile and conffile.
764+ * debian/maas.postinst:
765+ - Only run syncdb if dbconfig postinst file exists.
766+ - Fix file permissions.
767+ * debian/maas.{postrm,prerm}: Add dbconfig-common support.
768+ * Add txlongpoll support for packaging:
769+ - debian/control: Depends on python-txlongpoll.
770+ - debian/maas.maas-longpoll.upstart: Added to start txlongpoll.
771+ - debian/maas.install: Install txlongpoll.yaml
772+ * debian/extras/maas: Improvements.
773+ * debian/maas.maas.upstart: Moved from debian/maas.upstart.
774+ * debian/maas.postinst: Touch logfile to set correct permissions (LP: #955400)
775+ * debian/maas.logrotate: Add.
776+ * debian/patches/03-txlongpoll-config.patch: Add default settings.
777+ * debian/maas.config: Only run dbconfig-common on configure/reconfigure.
778+ * Install maas_local_settings.py in /etc/maas and symlink to usr/share/maas
779+ * Update references from MaaS to MAAS.
780+ * Remove podebconf as templates no longer exist.
781+ - debian/po: Remove.
782+ - debian/control: Drop Build-Depends on po-debconf
783+
784+ -- Andres Rodriguez <andreserl@ubuntu.com> Thu, 15 Mar 2012 15:28:14 -0400
785+
786+maas (0.1+bzr266+dfsg-0ubuntu1) precise; urgency=low
787+
788+ * Remove support for squid3 and use squid-deb-proxy instead.
789+ * debian/extras/maas: Add to handle syncdb and creation of admin user.
790+ * Add debconf questions to ask for user/pass:
791+ - debian/maas.{template,config}: Add
792+ - debian/maas.postinst: Ask debconf questions.
793+ - debian/po: Add translation templates.i
794+ * debian/maas.postinst: Enable wsgi module; drop squid3 steps.
795+ * debian/maas.postrm: removed.
796+ * debian/patches/01-fix-database-settings.patch: Custom database settings
797+ and static files path.
798+ * debian/{rules,maas.install}: Install maas static files in
799+ 'usr/share/maas/web/static'.
800+ * Integrate cobbler:
801+ - debian/maas.install: Install pserv twisted plugin, and config.
802+ - debian/maas.upstart: Created to start plugin daemon.
803+ - debian/patches/02-pserv-config.patch: Custom pserv config.
804+ * Integrate dbconfig-common:
805+ - debian/maas.config: Added and default user/pass and database.
806+ - debian/maas.{postinst,postrm}: Added handling for dbconfig-common
807+ * debian/control: Depends on python-convoy.
808+ * debian/rules: Update path to removal of dsfg files.
809+ * debian/patches/01-fix-database-settings.patch: Updated.
810+
811+ -- Andres Rodriguez <andreserl@ubuntu.com> Tue, 13 Mar 2012 14:31:50 -0400
812+
813+maas (0.1+bzr232+dfsg-0ubuntu1) precise; urgency=low
814+
815+ * New upstream snapshot.
816+
817+ [ Dave Walker ]
818+ * debian/control:
819+ - Changed depends from psycopg2 to python-psycopg2 and dropped versioning.
820+ - LP: #937982
821+
822+ [ Andres Rodriguez ]
823+ * debian/maas.install: Install maas-import-isos and related files.
824+ * Integrate squid3 as proxy solution:
825+ - debian/extras/squid.conf: Added
826+ - debian/control: Depend on squid3.
827+ - debian/maas.{postinst,postrm}: Handle installation/removal of custom
828+ squid config file.
829+ * Split into different binary packages (maas,python-django-maas).
830+ - debian/maas.postinst: Handle the apache2 configuration.
831+
832+ -- Andres Rodriguez <andreserl@ubuntu.com> Wed, 07 Mar 2012 12:46:17 -0500
833+
834+maas (0.1+bzr171+dfsg-0ubuntu1) precise; urgency=low
835+
836+ * New upstream snapshot, post 0.1 release.
837+ * debian/control:
838+ - Drop depends on rabbitmq-server, no longer required.
839+ * debian/watch: Introduced watch file.
840+
841+ -- Dave Walker (Daviey) <DaveWalker@ubuntu.com> Thu, 23 Feb 2012 13:08:12 +0000
842+
843+maas (0.1~bzr146+dfsg-0ubuntu1) precise; urgency=low
844+
845+ * Initial release
846+
847+ -- Julian Edwards <julian.edwards@canonical.com> Thu, 16 Jan 2012 15:29:07 +0000
848
849=== added file 'debian/compat'
850--- debian/compat 1970-01-01 00:00:00 +0000
851+++ debian/compat 2013-10-11 14:15:22 +0000
852@@ -0,0 +1,1 @@
853+7
854
855=== added file 'debian/control'
856--- debian/control 1970-01-01 00:00:00 +0000
857+++ debian/control 2013-10-11 14:15:22 +0000
858@@ -0,0 +1,283 @@
859+Source: maas
860+Section: net
861+Priority: optional
862+Maintainer: Ubuntu Developers <ubuntu-devel-discuss@lists.ubuntu.com>
863+Build-Depends: debhelper (>= 8.1.0~),
864+ dh-apport,
865+ po-debconf,
866+ python (>= 2.7),
867+ python-distribute,
868+ python-django
869+Standards-Version: 3.9.4
870+X-Python-Version: >= 2.7
871+Homepage: https://launchpad.net/maas
872+
873+Package: maas
874+Architecture: all
875+Depends: ${misc:Depends}, maas-cluster-controller, maas-region-controller, python-django-maas
876+Description: Ubuntu MAAS Server
877+ Ubuntu MAAS Server is the successor to Orchestra. It offers a
878+ nice UI to provision your Ubuntu servers. Each physical server
879+ (“node”) will be commissioned automatically on first boot.
880+ During the commissioning process administrators are able to
881+ configure hardware settings manually before an automated smoke
882+ test and burn-in test are done. Once commissioned, a node can
883+ be deployed on demand by name, or allocated to a queue for
884+ dynamic allocation to services being deployed on this MAAS.
885+ .
886+ This package is a metapackage which installs a complete MAAS
887+ service on a single machine.
888+
889+Package: maas-common
890+Architecture: all
891+Depends: ${misc:Depends}, ${python:Depends}
892+Breaks: maas ( <= 0.1+bzr1048+dfsg-0ubuntu1 )
893+Replaces: maas ( <= 0.1+bzr1048+dfsg-0ubuntu1 )
894+Description: Ubuntu MAAS Server
895+ Ubuntu MAAS Server is the successor to Orchestra. It offers a
896+ nice UI to provision your Ubuntu servers. Each physical server
897+ (“node”) will be commissioned automatically on first boot.
898+ During the commissioning process administrators are able to
899+ configure hardware settings manually before an automated smoke
900+ test and burn-in test are done. Once commissioned, a node can
901+ be deployed on demand by name, or allocated to a queue for
902+ dynamic allocation to services being deployed on this MAAS.
903+ .
904+ This package contains common files
905+
906+Package: maas-region-controller
907+Architecture: all
908+Depends: apache2,
909+ avahi-daemon,
910+ bind9utils,
911+ dbconfig-common,
912+ iproute,
913+ libapache2-mod-wsgi,
914+ libjs-raphael,
915+ libjs-yui3-full,
916+ libjs-yui3-min,
917+ maas-common (= ${binary:Version}),
918+ postgresql-9.1,
919+ pwgen,
920+ python-django (>= 1.4),
921+ python-django-maas (= ${binary:Version}),
922+ python-django-piston,
923+ python-django-south,
924+ python-maas-provisioningserver (= ${binary:Version}),
925+ python-djorm-ext-pgarray,
926+ rabbitmq-server,
927+ rsyslog,
928+ squid-deb-proxy,
929+ ${misc:Depends},
930+ ${python:Depends}
931+Recommends: openssh-server, maas-dns (= ${binary:Version})
932+Breaks: maas ( <= 0.1+bzr1048+dfsg-0ubuntu1 )
933+Replaces: maas ( <= 0.1+bzr1048+dfsg-0ubuntu1 )
934+Description: Ubuntu MAAS Server
935+ Ubuntu MAAS Server is the successor to Orchestra. It offers a
936+ nice UI to provision your Ubuntu servers. Each physical server
937+ (“node”) will be commissioned automatically on first boot.
938+ During the commissioning process administrators are able to
939+ configure hardware settings manually before an automated smoke
940+ test and burn-in test are done. Once commissioned, a node can
941+ be deployed on demand by name, or allocated to a queue for
942+ dynamic allocation to services being deployed on this MAAS.
943+ .
944+ This package installs the region controller services: the web
945+ UI and the database.
946+
947+Package: python-maas-provisioningserver
948+Section: python
949+Architecture: all
950+Depends: python-celery,
951+ python-distro-info,
952+ python-formencode,
953+ python-lockfile,
954+ python-lxml,
955+ python-maas-client,
956+ python-netifaces,
957+ python-oops,
958+ python-oops-amqp,
959+ python-oops-datedir-repo,
960+ python-oops-twisted,
961+ python-pyparsing,
962+ python-simplestreams,
963+ python-tempita,
964+ python-twisted-core,
965+ python-twisted-web,
966+ python-txamqp,
967+ python-txtftp,
968+ python-yaml,
969+ python-zope.interface,
970+ ${misc:Depends},
971+ ${python:Depends}
972+Breaks: python-django-maas ( <= 0.1+bzr1048+dfsg-0ubuntu1 ), maas-cluster-controller (<= 0.1+bzr1243+dfsg-0ubuntu3)
973+Replaces: python-django-maas ( <= 0.1+bzr1048+dfsg-0ubuntu1 ), maas-cluster-controller (<= 0.1+bzr1243+dfsg-0ubuntu3)
974+Description: Ubuntu MAAS Server
975+ Ubuntu MAAS Server is the successor to Orchestra. It offers a
976+ nice UI to provision your Ubuntu servers. Each physical server
977+ (“node”) will be commissioned automatically on first boot.
978+ During the commissioning process administrators are able to
979+ configure hardware settings manually before an automated smoke
980+ test and burn-in test are done. Once commissioned, a node can
981+ be deployed on demand by name, or allocated to a queue for
982+ dynamic allocation to services being deployed on this MAAS.
983+ .
984+ This package contains the provisioning server libraries.
985+
986+Package: maas-cli
987+Architecture: all
988+Depends: python-bzrlib,
989+ python-httplib2,
990+ python-maas-client (= ${binary:Version}),
991+ python-oauth,
992+ ${misc:Depends},
993+ ${python:Depends}
994+Description: Ubuntu MAAS Client Tool
995+ Ubuntu MAAS Server is the successor to Orchestra. It offers a
996+ nice UI to provision your Ubuntu servers. Each physical server
997+ (“node”) will be commissioned automatically on first boot.
998+ During the commissioning process administrators are able to
999+ configure hardware settings manually before an automated smoke
1000+ test and burn-in test are done. Once commissioned, a node can
1001+ be deployed on demand by name, or allocated to a queue for
1002+ dynamic allocation to services being deployed on this MAAS.
1003+ .
1004+ This package contains the client command line tool.
1005+
1006+Package: python-maas-client
1007+Section: python
1008+Architecture: all
1009+Depends: python-oauth, ${misc:Depends}, ${python:Depends}
1010+Breaks: maas (<= 0.1+bzr971+dfsg-0ubuntu2 )
1011+Replaces: maas (<= 0.1+bzr971+dfsg-0ubuntu2 )
1012+Description: Ubuntu MAAS API Client - (python files)
1013+ Ubuntu MAAS Server is the successor to Orchestra. It offers a
1014+ nice UI to provision your Ubuntu servers. Each physical server
1015+ (“node”) will be commissioned automatically on first boot.
1016+ During the commissioning process administrators are able to
1017+ configure hardware settings manually before an automated smoke
1018+ test and burn-in test are done. Once commissioned, a node can
1019+ be deployed on demand by name, or allocated to a queue for
1020+ dynamic allocation to services being deployed on this MAAS.
1021+ .
1022+ This package contains the client API Python modules.
1023+
1024+Package: maas-cluster-controller
1025+Architecture: all
1026+Depends: apache2,
1027+ bind9utils,
1028+ distro-info,
1029+ freeipmi-tools,
1030+ maas-cli (=${binary:Version}),
1031+ maas-common (=${binary:Version}),
1032+ maas-dhcp (=${binary:Version}),
1033+ python-celery,
1034+ python-httplib2,
1035+ python-lockfile,
1036+ python-maas-provisioningserver (=${binary:Version}),
1037+ python-netaddr,
1038+ python-oauth,
1039+ python-tempita,
1040+ python-twisted,
1041+ python-zope.interface,
1042+ rsyslog,
1043+ syslinux-common,
1044+ tgt,
1045+ ubuntu-cloudimage-keyring,
1046+ uuid-runtime,
1047+ wget,
1048+ ${misc:Depends},
1049+ ${python:Depends}
1050+Conflicts: tftpd-hpa
1051+Breaks: maas ( <= 0.1+bzr1048+dfsg-0ubuntu1 ), maas-region-controller ( <= 0.1+bzr1314+dfsg-0ubuntu1 )
1052+Replaces: maas ( <= 0.1+bzr1048+dfsg-0ubuntu1 ), maas-region-controller ( <= 0.1+bzr1314+dfsg-0ubuntu1 )
1053+Description: Ubuntu MAAS Cluster Controller
1054+ Ubuntu MAAS Server is the successor to Orchestra. It offers a
1055+ nice UI to provision your Ubuntu servers. Each physical server
1056+ (“node”) will be commissioned automatically on first boot.
1057+ During the commissioning process administrators are able to
1058+ configure hardware settings manually before an automated smoke
1059+ test and burn-in test are done. Once commissioned, a node can
1060+ be deployed on demand by name, or allocated to a queue for
1061+ dynamic allocation to services being deployed on this MAAS.
1062+ .
1063+ This package contains the cluster controller, which is
1064+ responsible for controlling remote DHCP/TFTP instances on their
1065+ own subnets.
1066+
1067+Package: python-django-maas
1068+Section: python
1069+Architecture: all
1070+Depends: python-avahi,
1071+ python-celery,
1072+ python-convoy,
1073+ python-curtin,
1074+ python-dbus,
1075+ python-lockfile,
1076+ python-lxml,
1077+ python-maas-client (= ${binary:Version}),
1078+ python-netaddr,
1079+ python-oops,
1080+ python-oops-amqp,
1081+ python-oops-datedir-repo,
1082+ python-oops-twisted,
1083+ python-oops-wsgi,
1084+ python-psycopg2,
1085+ python-sphinx,
1086+ python-tempita,
1087+ python-twisted,
1088+ python-txamqp,
1089+ python-txlongpoll,
1090+ python-zope.interface,
1091+ ${misc:Depends},
1092+ ${python:Depends}
1093+Description: Ubuntu MAAS Server - (django files)
1094+ Ubuntu MAAS Server is the successor to Orchestra. It offers a
1095+ nice UI to provision your Ubuntu servers. Each physical server
1096+ (“node”) will be commissioned automatically on first boot.
1097+ During the commissioning process administrators are able to
1098+ configure hardware settings manually before an automated smoke
1099+ test and burn-in test are done. Once commissioned, a node can
1100+ be deployed on demand by name, or allocated to a queue for
1101+ dynamic allocation to services being deployed on this MAAS.
1102+ .
1103+ This package contains the Django files.
1104+
1105+Package: maas-dhcp
1106+Architecture: all
1107+Depends: isc-dhcp-server (>= 4.2.4), ${misc:Depends}
1108+Breaks: maas-dhcp (<= 0.1+bzr777+dfsg-0ubuntu1)
1109+Replaces: maas-dhcp (<= 0.1+bzr777+dfsg-0ubuntu1)
1110+Description: Ubuntu MAAS Server - DHCP Configuration (meta-package)
1111+ Ubuntu MAAS Server is the successor to Orchestra. It offers a
1112+ nice UI to provision your Ubuntu servers. Each physical server
1113+ (“node”) will be commissioned automatically on first boot.
1114+ During the commissioning process administrators are able to
1115+ configure hardware settings manually before an automated smoke
1116+ test and burn-in test are done. Once commissioned, a node can
1117+ be deployed on demand by name, or allocated to a queue for
1118+ dynamic allocation to services being deployed on this MAAS.
1119+ .
1120+ This package configures a DHCP that can be used with MAAS.
1121+
1122+Package: maas-dns
1123+Architecture: all
1124+Depends: bind9,
1125+ maas-region-controller (= ${binary:Version}),
1126+ maas-dhcp (= ${binary:Version}),
1127+ ${misc:Depends}
1128+Conflicts: dnsmasq
1129+Breaks: maas-dhcp (<= 0.1+bzr777+dfsg-0ubuntu1)
1130+Replaces: maas-dhcp (<= 0.1+bzr777+dfsg-0ubuntu1)
1131+Description: Ubuntu MAAS Server - DNS configuration (metapackage)
1132+ Ubuntu MAAS Server is the successor to Orchestra. It offers a
1133+ nice UI to provision your Ubuntu servers. Each physical server
1134+ (“node”) will be commissioned automatically on first boot.
1135+ During the commissioning process administrators are able to
1136+ configure hardware settings manually before an automated smoke
1137+ test and burn-in test are done. Once commissioned, a node can
1138+ be deployed on demand by name, or allocated to a queue for
1139+ dynamic allocation to services being deployed on this MAAS.
1140+ .
1141+ This package configures a DNS that can be used with MAAS.
1142
1143=== added file 'debian/copyright'
1144--- debian/copyright 1970-01-01 00:00:00 +0000
1145+++ debian/copyright 2013-10-11 14:15:22 +0000
1146@@ -0,0 +1,25 @@
1147+Format: http://dep.debian.net/deps/dep5
1148+Upstream-Name: maas
1149+Source: https://launchpad.net/maas
1150+
1151+Files: *
1152+Copyright: 2012 Canonical Ltd.
1153+License: AGPL-3.0+
1154+
1155+Files: debian/*
1156+Copyright: 2012 Canonical Ltd.
1157+License: AGPL-3.0+
1158+
1159+License: AGPL-3.0+
1160+ This program is free software: you can redistribute it and/or modify
1161+ it under the terms of the GNU Affero General Public License as
1162+ published by the Free Software Foundation, either version 3 of the
1163+ License, or (at your option) any later version.
1164+ .
1165+ This program is distributed in the hope that it will be useful,
1166+ but WITHOUT ANY WARRANTY; without even the implied warranty of
1167+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1168+ GNU Affero General Public License for more details.
1169+ .
1170+ You should have received a copy of the GNU Affero General Public License
1171+ along with this program. If not, see <http://www.gnu.org/licenses/>.
1172
1173=== added directory 'debian/extras'
1174=== added file 'debian/extras/20-maas.conf'
1175--- debian/extras/20-maas.conf 1970-01-01 00:00:00 +0000
1176+++ debian/extras/20-maas.conf 2013-10-11 14:15:22 +0000
1177@@ -0,0 +1,32 @@
1178+# Enable the udp server for installation logging
1179+$ModLoad imudp
1180+$UDPServerRun 514
1181+$ModLoad imtcp # load TCP listener
1182+
1183+# The following section (certificates) was copied from orchestra, but is
1184+# not used here. In the future, if we needed secure ssl, then re-enable.
1185+# These files were created in the orchestra-logging-server's postinst
1186+#
1187+## make gtls driver the default
1188+#$DefaultNetstreamDriver gtls
1189+#
1190+## certificate files
1191+#$DefaultNetstreamDriverCAFile /var/lib/maas/ssl-cert-orchestra-ca.pem
1192+#$DefaultNetstreamDriverCertFile /var/lib/maas/.ssl/ssl-cert-orchestra.pem
1193+#$DefaultNetstreamDriverKeyFile /var/lib/maas/.ssl/ssl-cert-orchestra-pk.pem
1194+#
1195+#$InputTCPServerStreamDriverMode 1 # run driver in TLS-only mode
1196+#$InputTCPServerStreamDriverAuthMode anon # client is NOT authenticated
1197+#$InputTCPServerRun 10514 # start up listener at port 10514
1198+
1199+# Reduce message repetition
1200+$RepeatedMsgReduction on
1201+##$RepeatedMsgContainsOrigionalMsg on
1202+
1203+# Message templating
1204+$template MAASboot,"/var/log/maas/rsyslog/%HOSTNAME%/%$YEAR%/%$MONTH%/%$DAY%/messages"
1205+
1206+:fromhost-ip, !isequal, "127.0.0.1" ?MAASboot
1207+# Stop messages that came from anywhere else from going into other places
1208+# like /var/log/syslog. If you want to see these messages there, then comment below
1209+& ~
1210
1211=== added file 'debian/extras/99-maas'
1212--- debian/extras/99-maas 1970-01-01 00:00:00 +0000
1213+++ debian/extras/99-maas 2013-10-11 14:15:22 +0000
1214@@ -0,0 +1,4 @@
1215+# /etc/squid-deb-proxy/mirror-dstdomain.acl.d/99-maas
1216+#
1217+# Enable launchpad personal package archives for squid-deb-proxy
1218+ppa.launchpad.net
1219
1220=== added file 'debian/extras/99-maas-sudoers'
1221--- debian/extras/99-maas-sudoers 1970-01-01 00:00:00 +0000
1222+++ debian/extras/99-maas-sudoers 2013-10-11 14:15:22 +0000
1223@@ -0,0 +1,3 @@
1224+maas ALL= NOPASSWD: /usr/sbin/service maas-dhcp-server restart
1225+maas ALL= NOPASSWD: /usr/sbin/maas-provision
1226+maas ALL= NOPASSWD: SETENV: /usr/sbin/maas-import-pxe-files
1227
1228=== added file 'debian/extras/isc-dhcp-server.override'
1229--- debian/extras/isc-dhcp-server.override 1970-01-01 00:00:00 +0000
1230+++ debian/extras/isc-dhcp-server.override 2013-10-11 14:15:22 +0000
1231@@ -0,0 +1,1 @@
1232+manual
1233
1234=== added file 'debian/extras/maas'
1235--- debian/extras/maas 1970-01-01 00:00:00 +0000
1236+++ debian/extras/maas 2013-10-11 14:15:22 +0000
1237@@ -0,0 +1,8 @@
1238+#!/bin/sh
1239+if [ "$(id -u)" != "0" ]; then
1240+ echo "This utility may only be run as root." 1>&2
1241+ exit 1
1242+fi
1243+export PYTHONPATH="/usr/share/maas${PYTHONPATH:+:}${PYTHONPATH}"
1244+export DJANGO_SETTINGS_MODULE="maas.settings"
1245+exec /usr/bin/django-admin "$@"
1246
1247=== added file 'debian/extras/maas-cli'
1248--- debian/extras/maas-cli 1970-01-01 00:00:00 +0000
1249+++ debian/extras/maas-cli 2013-10-11 14:15:22 +0000
1250@@ -0,0 +1,2 @@
1251+#!/bin/sh
1252+exec python -m maascli "$@"
1253
1254=== added file 'debian/extras/maas-provision'
1255--- debian/extras/maas-provision 1970-01-01 00:00:00 +0000
1256+++ debian/extras/maas-provision 2013-10-11 14:15:22 +0000
1257@@ -0,0 +1,7 @@
1258+#!/bin/sh
1259+if [ "$(id -u)" != "0" ]; then
1260+ echo "This utility may only be run as root." 1>&2
1261+ exit 1
1262+fi
1263+export PYTHONPATH="/usr/share/maas${PYTHONPATH:+:}${PYTHONPATH}"
1264+exec /usr/bin/python -m provisioningserver "$@"
1265
1266=== added file 'debian/extras/maas-region-celeryd'
1267--- debian/extras/maas-region-celeryd 1970-01-01 00:00:00 +0000
1268+++ debian/extras/maas-region-celeryd 2013-10-11 14:15:22 +0000
1269@@ -0,0 +1,50 @@
1270+#!/usr/bin/python
1271+import os
1272+from grp import getgrnam
1273+from pwd import getpwnam
1274+
1275+def start_celery(args):
1276+ uid = getpwnam(args.user).pw_uid
1277+ gid = getgrnam(args.group).gr_gid
1278+
1279+ env = dict(os.environ, PYTHONPATH="/usr/share/maas")
1280+
1281+ command = [
1282+ 'celeryd',
1283+ '--logfile=%s' % args.logfile,
1284+ '--schedule=%s' % args.schedule,
1285+ '--loglevel=INFO',
1286+ '--beat',
1287+ '--queues=celery,master',
1288+ ]
1289+
1290+ # Change gid first, just in case changing the uid might deprive
1291+ # us of the privileges required to setgid.
1292+ os.setgid(gid)
1293+ os.setuid(uid)
1294+
1295+ os.execvpe(command[0], command, env=env)
1296+
1297+def main():
1298+ import argparse
1299+ parser = argparse.ArgumentParser(
1300+ description='MAAS celery daemon config options')
1301+ parser.add_argument(
1302+ '--user', '-u', metavar='USER', default='maas',
1303+ help="System user identity that should run the cluster controller.")
1304+ parser.add_argument(
1305+ '--group', '-g', metavar='GROUP', default='maas',
1306+ help="System group that should run the cluster controller.")
1307+ parser.add_argument(
1308+ '--logfile', '-l', metavar='LOGFILE', default='/var/log/maas/celery-region.log',
1309+ help="Location of the logfile.")
1310+ parser.add_argument(
1311+ '--schedule', '-s', metavar='SCHEDULE', default='/var/lib/maas/celerybeat-region-schedule',
1312+ help="Location of the beat schedule file.")
1313+
1314+ args = args = parser.parse_args()
1315+
1316+ start_celery(args)
1317+
1318+if __name__ == '__main__':
1319+ main()
1320
1321=== added file 'debian/extras/maas_remote_syslog_compress'
1322--- debian/extras/maas_remote_syslog_compress 1970-01-01 00:00:00 +0000
1323+++ debian/extras/maas_remote_syslog_compress 2013-10-11 14:15:22 +0000
1324@@ -0,0 +1,2 @@
1325+# Compress log files not changed in more than 48 hours:
1326+30 4 * * * root find /var/log/maas/rsyslog -type f -mtime +2 -exec bzip2 '{}' \;
1327
1328=== added file 'debian/maas-cli.install'
1329--- debian/maas-cli.install 1970-01-01 00:00:00 +0000
1330+++ debian/maas-cli.install 2013-10-11 14:15:22 +0000
1331@@ -0,0 +1,2 @@
1332+debian/extras/maas-cli usr/bin
1333+debian/tmp/usr/lib/python*/dist-packages/maascli
1334
1335=== added file 'debian/maas-cli.lintian-overrides'
1336--- debian/maas-cli.lintian-overrides 1970-01-01 00:00:00 +0000
1337+++ debian/maas-cli.lintian-overrides 2013-10-11 14:15:22 +0000
1338@@ -0,0 +1,1 @@
1339+maas-cli: binary-without-manpage usr/bin/maas-cli
1340
1341=== added file 'debian/maas-cluster-controller.config'
1342--- debian/maas-cluster-controller.config 1970-01-01 00:00:00 +0000
1343+++ debian/maas-cluster-controller.config 2013-10-11 14:15:22 +0000
1344@@ -0,0 +1,36 @@
1345+#!/bin/sh
1346+
1347+set -e
1348+
1349+. /usr/share/debconf/confmodule
1350+db_version 2.0
1351+
1352+# Only ask for new installations and reconfiguring.
1353+# XXX Fix to not ask when installing from the CD.
1354+if ([ "$1" = "configure" ] && [ -z "$2" ]); then
1355+
1356+ db_get maas-cluster-controller/maas-url || true
1357+ if [ -z "$RET" ]; then
1358+ # Attempt to pre-populate if installing on the region controller.
1359+ if [ -e /etc/maas/maas_local_settings.py ]; then
1360+ url=$(awk '$1 == "DEFAULT_MAAS_URL" { split($0,array,"\"")} END{print array[2] }' /etc/maas/maas_local_settings.py)
1361+ # If the URL doesn't end in /MAAS then add it. This helps upgrades from
1362+ # precise for which the URL didn't contain /MAAS, which is now required
1363+ if ! echo $url | grep -qs "/MAAS$"; then
1364+ url="${url}/MAAS"
1365+ fi
1366+ db_set maas-cluster-controller/maas-url "$url"
1367+ else
1368+ # Will only get here if dbconf value not already set, or
1369+ # /etc/maas/maas_local_settings.py doesn't exist.
1370+ db_input medium maas-cluster-controller/maas-url || true
1371+ db_go
1372+ fi
1373+ fi
1374+fi
1375+
1376+if [ "$1" = "reconfigure" ]; then
1377+ db_input high maas-cluster-controller/maas-url || true
1378+ db_go
1379+fi
1380+#DEBHELPER#
1381
1382=== added file 'debian/maas-cluster-controller.dirs'
1383--- debian/maas-cluster-controller.dirs 1970-01-01 00:00:00 +0000
1384+++ debian/maas-cluster-controller.dirs 2013-10-11 14:15:22 +0000
1385@@ -0,0 +1,1 @@
1386+etc/maas
1387
1388=== added file 'debian/maas-cluster-controller.install'
1389--- debian/maas-cluster-controller.install 1970-01-01 00:00:00 +0000
1390+++ debian/maas-cluster-controller.install 2013-10-11 14:15:22 +0000
1391@@ -0,0 +1,32 @@
1392+# Install twisted plugins
1393+twisted/plugins/maasps.py usr/share/pyshared/twisted/plugins
1394+
1395+# Install PSERV config file
1396+debian/tmp/etc/maas/pserv.yaml
1397+
1398+# Install cluster config file
1399+debian/tmp/etc/maas/maas_cluster.conf
1400+
1401+# Install celery config file
1402+debian/tmp/usr/share/maas/celeryconfig_cluster.py
1403+
1404+# Install local celery cluster config file
1405+debian/tmp/etc/maas/maas_local_celeryconfig_cluster.py
1406+
1407+# Install templates
1408+debian/tmp/etc/maas/templates/dhcp
1409+debian/tmp/etc/maas/templates/power
1410+debian/tmp/etc/maas/templates/pxe
1411+
1412+# Install maas-import-pxe-files and related files
1413+debian/tmp/usr/sbin/maas-import-pxe-files
1414+man/maas-import-pxe-files.8 usr/share/man/man8
1415+debian/tmp/etc/maas/import_ephemerals
1416+debian/tmp/etc/maas/import_pxe_files
1417+debian/tmp/usr/sbin/maas-import-ephemerals
1418+debian/tmp/usr/bin/uec2roottar
1419+
1420+# Install all other stuff
1421+debian/extras/99-maas-sudoers etc/sudoers.d
1422+debian/extras/isc-dhcp-server.override etc/init
1423+debian/tmp/etc/maas/maas-cluster-http.conf
1424
1425=== added file 'debian/maas-cluster-controller.links'
1426--- debian/maas-cluster-controller.links 1970-01-01 00:00:00 +0000
1427+++ debian/maas-cluster-controller.links 2013-10-11 14:15:22 +0000
1428@@ -0,0 +1,1 @@
1429+etc/maas/maas_local_celeryconfig_cluster.py usr/share/maas/maas_local_celeryconfig_cluster.py
1430
1431=== added file 'debian/maas-cluster-controller.lintian-overrides'
1432--- debian/maas-cluster-controller.lintian-overrides 1970-01-01 00:00:00 +0000
1433+++ debian/maas-cluster-controller.lintian-overrides 2013-10-11 14:15:22 +0000
1434@@ -0,0 +1,2 @@
1435+maas-cluster-controller: binary-without-manpage usr/sbin/maas-import-ephemerals
1436+maas-cluster-controller: binary-without-manpage usr/bin/uec2roottar
1437
1438=== added file 'debian/maas-cluster-controller.logrotate'
1439--- debian/maas-cluster-controller.logrotate 1970-01-01 00:00:00 +0000
1440+++ debian/maas-cluster-controller.logrotate 2013-10-11 14:15:22 +0000
1441@@ -0,0 +1,9 @@
1442+/var/log/maas/pserv.log {
1443+ rotate 5
1444+ weekly
1445+ compress
1446+ missingok
1447+ postrotate
1448+ [ -r /var/run/maas-pserv.pid ] && kill -s USR2 $(cat /var/run/maas-pserv.pid) || true
1449+ endscript
1450+}
1451
1452=== added file 'debian/maas-cluster-controller.maas-cluster-celery.upstart'
1453--- debian/maas-cluster-controller.maas-cluster-celery.upstart 1970-01-01 00:00:00 +0000
1454+++ debian/maas-cluster-controller.maas-cluster-celery.upstart 2013-10-11 14:15:22 +0000
1455@@ -0,0 +1,30 @@
1456+# maas-cluster-controller - provisioning service
1457+#
1458+# MAAS Cluster Controller Service
1459+
1460+description "MAAS Cluster Controller"
1461+author "Julian Edwards <julian.edwards@canonical.com>"
1462+
1463+start on filesystem and net-device-up
1464+stop on runlevel [016]
1465+
1466+env CONFIG_FILE=/etc/maas/maas_cluster.conf
1467+# Use cluster config.
1468+env CELERY_CONFIG_MODULE="celeryconfig_cluster"
1469+
1470+pre-start script
1471+ if [ ! -f $CONFIG_FILE ]; then
1472+ echo "$CONFIG_FILE does not exist. Aborting."
1473+ stop
1474+ exit 0
1475+ fi
1476+end script
1477+
1478+script
1479+ # Prepare settings.
1480+ . $CONFIG_FILE
1481+ # Allow the cluster-controller process to read CLUSTER_UUID as set
1482+ # in that config file.
1483+ export CLUSTER_UUID
1484+ exec /usr/sbin/maas-provision start-cluster-controller $MAAS_URL -u maas -g maas
1485+end script
1486
1487=== added file 'debian/maas-cluster-controller.maas-pserv.upstart'
1488--- debian/maas-cluster-controller.maas-pserv.upstart 1970-01-01 00:00:00 +0000
1489+++ debian/maas-cluster-controller.maas-pserv.upstart 2013-10-11 14:15:22 +0000
1490@@ -0,0 +1,31 @@
1491+# maas-pserv - provisioning service
1492+#
1493+# MAAS Provisioning Service
1494+
1495+description "MAAS"
1496+author "Andres Rodriguez <andres.rodriguez@canonical.com>"
1497+
1498+start on filesystem and net-device-up
1499+stop on runlevel [016]
1500+
1501+respawn
1502+
1503+env CONFIG_FILE=/etc/maas/maas_cluster.conf
1504+
1505+pre-start script
1506+ if [ ! -f $CONFIG_FILE ]; then
1507+ echo "$CONFIG_FILE does not exist. Aborting."
1508+ stop
1509+ exit 0
1510+ fi
1511+end script
1512+
1513+script
1514+ # Prepare settings.
1515+ . $CONFIG_FILE
1516+ # Allow the tftpd process to read CLUSTER_UUID as set in that config
1517+ # file.
1518+ export CLUSTER_UUID
1519+ # To add options to your daemon, edit the line below:
1520+ exec /usr/bin/twistd -n --uid=maas --gid=maas --pidfile=/run/maas-pserv.pid --logfile=/dev/null maas-pserv --config-file=/etc/maas/pserv.yaml
1521+end script
1522
1523=== added file 'debian/maas-cluster-controller.postinst'
1524--- debian/maas-cluster-controller.postinst 1970-01-01 00:00:00 +0000
1525+++ debian/maas-cluster-controller.postinst 2013-10-11 14:15:22 +0000
1526@@ -0,0 +1,149 @@
1527+#!/bin/sh
1528+
1529+set -e
1530+
1531+. /usr/share/debconf/confmodule
1532+db_version 2.0
1533+
1534+RELEASE=`lsb_release -rs` || RELEASE=""
1535+
1536+create_log_dir() {
1537+ # create log dir
1538+ if [ ! -d /var/lib/maas ]; then
1539+ mkdir -p /var/lib/maas
1540+ fi
1541+ if [ ! -d /var/log/maas/oops ]; then
1542+ mkdir -p /var/log/maas/oops
1543+ fi
1544+ # Give appropriate permissions
1545+ chown -R maas:maas /var/lib/maas/
1546+ chown -R maas:maas /var/log/maas
1547+ chmod -R 775 /var/log/maas/oops
1548+}
1549+
1550+configure_maas_tgt(){
1551+ # Set up iSCSI: add maas.conf to tgt conf.d.
1552+ local tgtcfg="/etc/tgt/targets.conf"
1553+ [ -d /etc/tgt/conf.d/ ] ||
1554+ echo "Warning! $tgtcfg did not exist" 1>&2;
1555+ mkdir -p /etc/tgt/conf.d/ /var/lib/maas/ephemeral/
1556+ ln -sf /var/lib/maas/ephemeral/tgt.conf /etc/tgt/conf.d/maas.conf
1557+}
1558+
1559+extract_cluster_uuid(){
1560+ # Extract ClUSTER_UUID setting from config file $1. This will work
1561+ # both the cluster celery config (which is python) and the cluster
1562+ # config (which is shell).
1563+ sed -n -e "s/^CLUSTER_UUID *= *[\"']\([^\"']*\).*/\1/p" "$1"
1564+}
1565+
1566+configure_cluster_uuid(){
1567+ # The cluster uuid goes into maas_cluster.conf, but we also still
1568+ # keep a copy in maas_local_celeryconfig_cluster.py (hopefully just
1569+ # temporarily). If an old uuid is configured, we replicate that to
1570+ # maas_cluster.conf; otherwise, we want to generate one.
1571+ local uuid
1572+
1573+
1574+ if [ -n "$(extract_cluster_uuid /etc/maas/maas_cluster.conf)" ]; then
1575+ # UUID is already set up. Wonderful.
1576+ return
1577+ fi
1578+
1579+ # Look for a UUID stored in the old location.
1580+ uuid="$(extract_cluster_uuid /etc/maas/maas_local_celeryconfig_cluster.py)"
1581+
1582+ if [ -z "$uuid" ]; then
1583+ # No UUID at all yet. Generate one, and insert it into its
1584+ # placeholder in the old config location.
1585+ uuid="$(uuidgen)"
1586+ sed -i "s|^CLUSTER_UUID = None$|CLUSTER_UUID = '$uuid'|" \
1587+ /etc/maas/maas_local_celeryconfig_cluster.py
1588+ fi
1589+
1590+ # Either way, at this point we have a uuid, and it is configured in
1591+ # the old config location.
1592+ #
1593+ # Write it to maas_cluster.conf as well. There is no initial
1594+ # placeholder in this file, so just append the setting.
1595+ echo "CLUSTER_UUID=\"$uuid\"" >>/etc/maas/maas_cluster.conf
1596+}
1597+
1598+enable_apache_version_mod(){
1599+ COMMON_STATE=$(dpkg-query -f '${Status}' -W 'apache2.2-common' 2>/dev/null | awk '{print $3}' || true)
1600+ if [ "$COMMON_STATE" = "installed" ] || [ "$COMMON_STATE" = "unpacked" ] ; then
1601+ a2enmod version
1602+ fi
1603+}
1604+
1605+configure_cluster_http(){
1606+ case $RELEASE in
1607+ 12.04|12.10|13.04)
1608+ if [ -e /etc/maas/maas-cluster-http.conf -a \
1609+ ! -e /etc/apache2/conf.d/maas-cluster-http.conf ]; then
1610+ ln -sf /etc/maas/maas-cluster-http.conf /etc/apache2/conf.d/maas-cluster-http.conf
1611+ fi
1612+ ;;
1613+ *)
1614+ # handle apache configs
1615+ if [ -e /etc/maas/maas-cluster-http.conf -a \
1616+ ! -e /etc/apache2/conf-enabled/maas-cluster-http.conf ]; then
1617+ ln -sf /etc/maas/maas-cluster-http.conf /etc/apache2/conf-enabled/maas-cluster-http.conf
1618+ fi
1619+ ;;
1620+ esac
1621+}
1622+
1623+restart_apache2(){
1624+ if [ -x /usr/sbin/invoke-rc.d ]; then
1625+ invoke-rc.d apache2 restart || true
1626+ else
1627+ /etc/init.d/apache2 restart || true
1628+ fi
1629+}
1630+
1631+
1632+
1633+if [ "$1" = "configure" ] && [ -z "$2" ]; then
1634+ # logging
1635+ create_log_dir
1636+ configure_maas_tgt
1637+fi
1638+
1639+if ([ "$1" = "configure" ] && [ -z "$2" ]) || [ -n "$DEBCONF_RECONFIGURE" ]; then
1640+
1641+ if dpkg --compare-versions "$2" lt 0.1+bzr1239+dfsg-0ubuntu1; then
1642+ create_log_dir
1643+ fi
1644+
1645+ # Get the MAAS_URL on configure/reconfigure and write it to the conf files.
1646+ db_get maas-cluster-controller/maas-url || true
1647+ if [ -n "$RET" ]; then
1648+ sed -i "s|MAAS_URL=.*|MAAS_URL=\"$RET\"|" /etc/maas/maas_cluster.conf
1649+ # Extract the hostname part.
1650+ HOSTPART=$(echo $RET|awk '{ split($0,array,"/")} END{print array[3] }')
1651+ # And substitute it in-place in pserv.yaml on an indented, non-commented
1652+ # line.
1653+ sed -ri "s|^([[:space:]]+)(#+[[:space:]]*)?(generator:[[:space:]]+https?://)[^:/]+|\1\3$HOSTPART|" /etc/maas/pserv.yaml
1654+ fi
1655+fi
1656+
1657+if [ "$1" = "configure" ]; then
1658+ # These config files may contain a private cluster UUID. Only maas
1659+ # can read them; only root can write them
1660+ chown root:maas \
1661+ /etc/maas/maas_local_celeryconfig_cluster.py \
1662+ /etc/maas/maas_cluster.conf
1663+ chmod 0640 \
1664+ /etc/maas/maas_local_celeryconfig_cluster.py \
1665+ /etc/maas/maas_cluster.conf
1666+
1667+ configure_cluster_uuid
1668+ enable_apache_version_mod
1669+ configure_cluster_http
1670+ restart_apache2
1671+fi
1672+
1673+db_stop
1674+
1675+#DEBHELPER#
1676
1677=== added file 'debian/maas-cluster-controller.postrm'
1678--- debian/maas-cluster-controller.postrm 1970-01-01 00:00:00 +0000
1679+++ debian/maas-cluster-controller.postrm 2013-10-11 14:15:22 +0000
1680@@ -0,0 +1,38 @@
1681+#!/bin/sh
1682+
1683+set -e
1684+
1685+#DEBHELPER#
1686+
1687+RELEASE=`lsb_release -rs` || RELEASE=""
1688+
1689+case "$1" in
1690+ purge)
1691+ # remove log directory
1692+ rm -rf /var/log/maas
1693+ case $RELEASE in
1694+ 12.04|12.10|13.04)
1695+ if [ -h /etc/apache2/conf.d/maas-cluster-http.conf ]; then
1696+ rm -rf /etc/apache2/conf.d/maas-cluster-http.conf
1697+ fi
1698+ ;;
1699+ *)
1700+ # remove apache2 config
1701+ if [ -h /etc/apache2/conf-enabled/maas-cluster-http.conf ]; then
1702+ rm -rf /etc/apache2/conf-enabled/maas-cluster-http.conf
1703+ fi
1704+ ;;
1705+ esac
1706+ # remove var directory
1707+ rm -rf /var/lib/maas/celerybeat-cluster-schedule
1708+ DIR=/var/lib/maas
1709+ if [ "$(ls -A $DIR 2> /dev/null)" = "" ]; then
1710+ rm -rf /var/lib/maas
1711+ fi
1712+
1713+ # Delete symlink for iSCSI config.
1714+ if [ -L /etc/tgt/conf.d/maas.conf ]; then
1715+ rm -rf /etc/tgt/conf.d/maas.conf
1716+ fi
1717+
1718+esac
1719
1720=== added file 'debian/maas-cluster-controller.templates'
1721--- debian/maas-cluster-controller.templates 1970-01-01 00:00:00 +0000
1722+++ debian/maas-cluster-controller.templates 2013-10-11 14:15:22 +0000
1723@@ -0,0 +1,7 @@
1724+Template: maas-cluster-controller/maas-url
1725+Type: string
1726+Default:
1727+_Description: Ubuntu MAAS API address:
1728+ The MAAS Cluster Controller needs to contact the MAAS server to
1729+ register its presence. Set the URL to the MAAS API here, e.g.
1730+ http://192.168.1.1/MAAS
1731
1732=== added file 'debian/maas-common.install'
1733--- debian/maas-common.install 1970-01-01 00:00:00 +0000
1734+++ debian/maas-common.install 2013-10-11 14:15:22 +0000
1735@@ -0,0 +1,2 @@
1736+# Install Celery Config
1737+debian/tmp/usr/share/maas/celeryconfig_common.py
1738
1739=== added file 'debian/maas-common.postinst'
1740--- debian/maas-common.postinst 1970-01-01 00:00:00 +0000
1741+++ debian/maas-common.postinst 2013-10-11 14:15:22 +0000
1742@@ -0,0 +1,14 @@
1743+#!/bin/sh
1744+
1745+set -e
1746+
1747+add_user_group(){
1748+ local user="maas"
1749+ local group="maas"
1750+ addgroup --quiet --system "$group" || true
1751+ adduser --quiet --system --group --no-create-home "$user" || true
1752+}
1753+
1754+add_user_group
1755+
1756+#DEBHELPER#
1757
1758=== added file 'debian/maas-common.postrm'
1759--- debian/maas-common.postrm 1970-01-01 00:00:00 +0000
1760+++ debian/maas-common.postrm 2013-10-11 14:15:22 +0000
1761@@ -0,0 +1,14 @@
1762+#!/bin/sh
1763+
1764+set -e
1765+
1766+case "$1" in
1767+ purge)
1768+ # Deleting user/group
1769+ if getent passwd maas >/dev/null; then
1770+ deluser maas || true
1771+ delgroup maas || true
1772+ fi
1773+esac
1774+
1775+#DEBHELPER#
1776
1777=== added file 'debian/maas-dhcp.apparmor'
1778--- debian/maas-dhcp.apparmor 1970-01-01 00:00:00 +0000
1779+++ debian/maas-dhcp.apparmor 2013-10-11 14:15:22 +0000
1780@@ -0,0 +1,7 @@
1781+/run/maas/dhcp/ r,
1782+/run/maas/dhcp/** r,
1783+/run/maas/dhcp/*.pid lrw,
1784+/run/maas/dhcp/*.trace lrw,
1785+/run/maas/dhcp/*.leases* lrw,
1786+/var/lib/maas/dhcp/dhcpd*.leases* lrw,
1787+/etc/maas/dhcpd.conf r,
1788
1789=== added file 'debian/maas-dhcp.install'
1790--- debian/maas-dhcp.install 1970-01-01 00:00:00 +0000
1791+++ debian/maas-dhcp.install 2013-10-11 14:15:22 +0000
1792@@ -0,0 +1,1 @@
1793+/debian/tmp/etc/apparmor.d/dhcpd.d/maas
1794
1795=== added file 'debian/maas-dhcp.maas-dhcp-server.upstart'
1796--- debian/maas-dhcp.maas-dhcp-server.upstart 1970-01-01 00:00:00 +0000
1797+++ debian/maas-dhcp.maas-dhcp-server.upstart 2013-10-11 14:15:22 +0000
1798@@ -0,0 +1,65 @@
1799+description "MAAS instance of ISC DHCP server"
1800+author "Jeroen Vermeulen <jtv@canonical.com>"
1801+
1802+start on runlevel [2345]
1803+stop on runlevel [!2345]
1804+
1805+env CONFIG_FILE=/etc/maas/dhcpd.conf
1806+env PID_DIR=/run/maas/dhcp
1807+env PID_FILE=/run/maas/dhcp/dhcpd.pid
1808+env LEASES_DIR=/var/lib/maas/dhcp
1809+env LEASES_FILE=/var/lib/maas/dhcp/dhcpd.leases
1810+
1811+# This is where we write what interfaces dhcpd should listen on.
1812+env INTERFACES_FILE=/var/lib/maas/dhcpd-interfaces
1813+
1814+pre-start script
1815+ if [ ! -f $CONFIG_FILE ]; then
1816+ echo "$CONFIG_FILE does not exist. Aborting."
1817+ stop
1818+ exit 0
1819+ fi
1820+
1821+ if [ ! -f $INTERFACES_FILE ]; then
1822+ echo "$INTERFACES_FILE does not exist. Aborting."
1823+ stop
1824+ exit 0
1825+ fi
1826+
1827+ if ! /usr/sbin/dhcpd -t -q -4 -cf $CONFIG_FILE > /dev/null 2>&1; then
1828+ echo "dhcpd self-test failed. Please fix the config file."
1829+ echo "The error was: "
1830+ /usr/sbin/dhcpd -t -4 -cf $CONFIG_FILE
1831+ stop
1832+ exit 0
1833+ fi
1834+end script
1835+
1836+respawn
1837+script
1838+ INTERFACES=`cat "${INTERFACES_FILE}"`
1839+
1840+ # Allow dhcp server to write lease and pid file.
1841+ mkdir -p $PID_DIR
1842+ chown dhcpd:dhcpd $PID_DIR
1843+
1844+ # As of Quantal, the leases file must be owned by root:root (even though
1845+ # the daemon will run under an unprivileged user).
1846+ # In Precise, ownership was supposed to be dhcpd:dhcpd.
1847+ #
1848+ # maas packages on saucy are only supported with newer isc-dhcp via
1849+ # the cloud-archive. See bug 1231693 for more information, including
1850+ # a patch that would actually work to support all, but is complex.
1851+
1852+ mkdir -p $LEASES_DIR
1853+ chown root:root $LEASES_DIR
1854+ [ -e $LEASES_FILE ] || touch $LEASES_FILE
1855+ for LFILE in $LEASES_FILE $LEASES_FILE~; do
1856+ if [ -e $LFILE ]; then
1857+ chown root:root $LFILE
1858+ chmod a+r $LFILE
1859+ fi
1860+ done
1861+
1862+ exec /usr/sbin/dhcpd -user dhcpd -group dhcpd -f -q -4 -pf $PID_FILE -cf $CONFIG_FILE -lf $LEASES_FILE $INTERFACES
1863+end script
1864
1865=== added file 'debian/maas-dhcp.postinst'
1866--- debian/maas-dhcp.postinst 1970-01-01 00:00:00 +0000
1867+++ debian/maas-dhcp.postinst 2013-10-11 14:15:22 +0000
1868@@ -0,0 +1,15 @@
1869+#!/bin/sh
1870+
1871+set -e
1872+
1873+if [ "$1" = "configure" ]; then
1874+ invoke-rc.d isc-dhcp-server stop
1875+
1876+ dhcpd_prof="/etc/apparmor.d/usr.sbin.dhcpd"
1877+ if [ -f "${dhcpd_prof}" ] && command -v apparmor_parser >/dev/null 2>&1
1878+ then
1879+ apparmor_parser --replace --write-cache --skip-read-cache "${dhcpd_prof}" || true
1880+ fi
1881+fi
1882+
1883+#DEBHELPER#
1884
1885=== added file 'debian/maas-dhcp.postrm'
1886--- debian/maas-dhcp.postrm 1970-01-01 00:00:00 +0000
1887+++ debian/maas-dhcp.postrm 2013-10-11 14:15:22 +0000
1888@@ -0,0 +1,13 @@
1889+#!/bin/sh
1890+
1891+set -e
1892+
1893+if [ "$1" = "remove" ] || [ "$1" = "purge" ]; then
1894+ dhcpd_prof="/etc/apparmor.d/usr.sbin.dhcpd"
1895+ if [ -f "${dhcpd_prof}" ] &&
1896+ command -v apparmor_parser >/dev/null 2>&1; then
1897+ apparmor_parser --replace --write-cache --skip-read-cache "${dhcpd_prof}"
1898+ fi
1899+fi
1900+
1901+#DEBHELPER#
1902
1903=== added file 'debian/maas-dns.dirs'
1904--- debian/maas-dns.dirs 1970-01-01 00:00:00 +0000
1905+++ debian/maas-dns.dirs 2013-10-11 14:15:22 +0000
1906@@ -0,0 +1,1 @@
1907+etc/bind/maas
1908
1909=== added file 'debian/maas-dns.postinst'
1910--- debian/maas-dns.postinst 1970-01-01 00:00:00 +0000
1911+++ debian/maas-dns.postinst 2013-10-11 14:15:22 +0000
1912@@ -0,0 +1,36 @@
1913+#!/bin/sh
1914+
1915+set -e
1916+
1917+if ([ "$1" = "configure" ] && [ -z "$2" ]) || [ -n "$DEBCONF_RECONFIGURE" ]; then
1918+ # If /etc/bind/maas is empty, set_up_dns.
1919+ if [ ! "$(ls -A /etc/bind/maas)" ]; then
1920+ maas set_up_dns
1921+ fi
1922+
1923+ # Fix permissions.
1924+ if [ -d /etc/bind/maas ]; then
1925+ chown -R maas:root /etc/bind/maas
1926+ fi
1927+ if [ -f /etc/bind/maas/named.conf.maas ]; then
1928+ chmod 644 /etc/bind/maas/named.conf.maas
1929+ fi
1930+ if [ -f /etc/bind/maas/rndc.conf.maas ]; then
1931+ chmod 600 /etc/bind/maas/rndc.conf.maas
1932+ fi
1933+ if [ -f /etc/bind/maas/named.conf.rndc.maas ]; then
1934+ chown maas:bind /etc/bind/maas/named.conf.rndc.maas
1935+ chmod 640 /etc/bind/maas/named.conf.rndc.maas
1936+ fi
1937+
1938+ # Remove any existing MAAS-related include line from
1939+ # /etc/bind/named.conf.local, then re-add it.
1940+ sed -i '/^include\s.*maas/d' /etc/bind/named.conf.local
1941+ maas get_named_conf --edit --config_path /etc/bind/named.conf.local
1942+
1943+ maas write_dns_config
1944+
1945+ invoke-rc.d bind9 restart || true
1946+fi
1947+
1948+#DEBHELPER#
1949
1950=== added file 'debian/maas-dns.postrm'
1951--- debian/maas-dns.postrm 1970-01-01 00:00:00 +0000
1952+++ debian/maas-dns.postrm 2013-10-11 14:15:22 +0000
1953@@ -0,0 +1,23 @@
1954+#!/bin/sh
1955+
1956+set -e
1957+
1958+if [ "$1" = "remove" ]; then
1959+ if [ -f /etc/bind/named.conf.local ]; then
1960+ sed -i '/^include.*\"\/etc\/bind\/maas\/named.conf.maas\"\;$/d' \
1961+ /etc/bind/named.conf.local
1962+ fi
1963+fi
1964+
1965+if [ "$1" = "purge" ]; then
1966+ # Remove zone files
1967+ if [ -d /etc/bind/maas ]; then
1968+ rm -rf /etc/bind/maas
1969+ fi
1970+fi
1971+
1972+if [ -x /usr/sbin/invoke-rc.d ]; then
1973+ invoke-rc.d bind9 restart || true
1974+fi
1975+
1976+#DEBHELPER#
1977
1978=== added file 'debian/maas-region-controller.apport'
1979--- debian/maas-region-controller.apport 1970-01-01 00:00:00 +0000
1980+++ debian/maas-region-controller.apport 2013-10-11 14:15:22 +0000
1981@@ -0,0 +1,37 @@
1982+#!/usr/bin/python
1983+
1984+'''apport hook for bind9
1985+
1986+(c) 2012 Canonical Ltd.
1987+Author: Andres Rodriguez <andres.rodriguez@canonical.com>
1988+
1989+This program is free software; you can redistribute it and/or modify it
1990+under the terms of the GNU General Public License as published by the
1991+Free Software Foundation; either version 2 of the License, or (at your
1992+option) any later version. See http://www.gnu.org/copyleft/gpl.html for
1993+the full text of the license.
1994+'''
1995+
1996+from apport.hookutils import *
1997+
1998+def add_info(report, ui):
1999+ response = ui.yesno("The contents of your /etc/maas/maas_local_settings.py, "
2000+ "/etc/maas/txlongpoll.yaml, /etc/maas/pserv.yaml files "
2001+ "may help developers diagnose your bug more "
2002+ "quickly. However, it may contain sensitive "
2003+ "information. Do you want to include it in your "
2004+ "bug report?")
2005+
2006+ if response == None: # user cancelled
2007+ raise StopIteration
2008+
2009+ elif response == True:
2010+ attach_conffiles(report,'maas')
2011+
2012+ # Attaching log files
2013+ attach_file_if_exists(report, '/var/log/maas/maas.log', 'MAASLog')
2014+ attach_file_if_exists(report, '/var/log/maas/pserv.log', 'MAASPservLog')
2015+ attach_file_if_exists(report, '/var/log/maas/txlongpoll.log', 'MAAStxlongpollLog')
2016+
2017+ # Attaching related packages info
2018+ attach_related_packages(report, ['python-django-maas', 'apparmor'])
2019
2020=== added file 'debian/maas-region-controller.config'
2021--- debian/maas-region-controller.config 1970-01-01 00:00:00 +0000
2022+++ debian/maas-region-controller.config 2013-10-11 14:15:22 +0000
2023@@ -0,0 +1,45 @@
2024+#!/bin/sh
2025+
2026+set -e
2027+
2028+. /usr/share/debconf/confmodule
2029+db_version 2.0
2030+
2031+# creates question
2032+set_question() {
2033+ if ! db_fget "$1" seen; then
2034+ db_register dbconfig-common/dbconfig-install "$1"
2035+ db_subst "$1" ID "$1"
2036+ db_fget "$1" seen
2037+ fi
2038+ if [ "$RET" = false ]; then
2039+ db_set "$1" "$2"
2040+ db_fset "$1" seen true
2041+ fi
2042+}
2043+
2044+# source dbconfig-common shell library, and call the hook function
2045+if [ -f /usr/share/dbconfig-common/dpkg/config.pgsql ]; then
2046+ . /usr/share/dbconfig-common/dpkg/config.pgsql
2047+fi
2048+
2049+if [ "$1" = "configure" ] && [ -z "$2" ]; then
2050+ # Hide maas/dbconfig-install question by setting default.
2051+ set_question maas-region-controller/dbconfig-install true
2052+ set_question maas-region-controller/pgsql/app-pass ""
2053+
2054+ dbc_dbname="maasdb"
2055+ dbc_dbuser="maas"
2056+ dbc_remove="true"
2057+
2058+ dbc_go maas-region-controller $@
2059+
2060+elif [ -n "$DEBCONF_RECONFIGURE" ]; then
2061+ db_get maas/default-maas-url || true
2062+ if [ -z "$RET" ]; then
2063+ ipaddr=$(awk '$1 == "DEFAULT_MAAS_URL" { split($0,array,"/")} END{print array[3] }' /etc/maas/maas_local_settings.py)
2064+ db_set maas/default-maas-url "$ipaddr"
2065+ fi
2066+ db_input low maas/default-maas-url || true
2067+ db_go
2068+fi
2069
2070=== added file 'debian/maas-region-controller.dirs'
2071--- debian/maas-region-controller.dirs 1970-01-01 00:00:00 +0000
2072+++ debian/maas-region-controller.dirs 2013-10-11 14:15:22 +0000
2073@@ -0,0 +1,2 @@
2074+var/log/maas/oops
2075+var/lib/maas/tftp
2076
2077=== added file 'debian/maas-region-controller.install'
2078--- debian/maas-region-controller.install 1970-01-01 00:00:00 +0000
2079+++ debian/maas-region-controller.install 2013-10-11 14:15:22 +0000
2080@@ -0,0 +1,37 @@
2081+# Install project
2082+debian/tmp/usr/lib/python*/dist-packages/maas usr/share/maas
2083+
2084+# Install static files
2085+debian/tmp/usr/share/maas/web/static
2086+
2087+# Install Apache Config
2088+debian/tmp/etc/maas/maas-http.conf
2089+
2090+# Install MAAS local settings
2091+debian/tmp/etc/maas/maas_local_settings.py
2092+
2093+# Install celery config file
2094+debian/tmp/usr/share/maas/celeryconfig.py
2095+
2096+# Install local celery region config file
2097+debian/tmp/etc/maas/maas_local_celeryconfig.py
2098+
2099+# Install WSGI
2100+debian/tmp/usr/share/maas/wsgi.py
2101+
2102+# Install txlongpoll config file
2103+debian/tmp/etc/maas/txlongpoll.yaml
2104+
2105+# Install new preseed files
2106+debian/tmp/etc/maas/preseeds
2107+
2108+# Install templates
2109+debian/tmp/etc/maas/templates/dns
2110+debian/tmp/etc/maas/templates/commissioning-user-data
2111+
2112+# Install all other stuff
2113+debian/extras/maas usr/sbin
2114+debian/extras/maas-region-celeryd usr/sbin
2115+debian/extras/20-maas.conf etc/rsyslog.d
2116+debian/extras/maas_remote_syslog_compress etc/cron.d
2117+debian/extras/99-maas usr/share/maas/conf
2118
2119=== added file 'debian/maas-region-controller.links'
2120--- debian/maas-region-controller.links 1970-01-01 00:00:00 +0000
2121+++ debian/maas-region-controller.links 2013-10-11 14:15:22 +0000
2122@@ -0,0 +1,2 @@
2123+etc/maas/maas_local_settings.py usr/share/maas/maas_local_settings.py
2124+etc/maas/maas_local_celeryconfig.py usr/share/maas/maas_local_celeryconfig.py
2125
2126=== added file 'debian/maas-region-controller.lintian-overrides'
2127--- debian/maas-region-controller.lintian-overrides 1970-01-01 00:00:00 +0000
2128+++ debian/maas-region-controller.lintian-overrides 2013-10-11 14:15:22 +0000
2129@@ -0,0 +1,6 @@
2130+maas-region-controller: binary-without-manpage usr/sbin/maas
2131+maas-region-controller: binary-without-manpage usr/sbin/maas-region-celeryd
2132+maas-region-controller: script-not-executable etc/maas/templates/commissioning-user-data/snippets/maas_ipmi_autodetect.py
2133+maas-region-controller: script-not-executable etc/maas/templates/commissioning-user-data/snippets/maas_signal.py
2134+maas-region-controller: script-not-executable etc/maas/templates/commissioning-user-data/user_data.template
2135+maas-region-controller: script-not-executable etc/maas/templates/commissioning-user-data/snippets/maas_get.py
2136
2137=== added file 'debian/maas-region-controller.logrotate'
2138--- debian/maas-region-controller.logrotate 1970-01-01 00:00:00 +0000
2139+++ debian/maas-region-controller.logrotate 2013-10-11 14:15:22 +0000
2140@@ -0,0 +1,18 @@
2141+/var/log/maas/maas.log {
2142+ rotate 5
2143+ weekly
2144+ compress
2145+ copytruncate
2146+ missingok
2147+ #create 620 root www-data
2148+}
2149+
2150+/var/log/maas/txlongpoll.log {
2151+ rotate 5
2152+ weekly
2153+ compress
2154+ missingok
2155+ postrotate
2156+ [ -r /var/run/maas-txlongpoll.pid ] && kill -s USR2 $(cat /var/run/maas-txlongpoll.pid) || true
2157+ endscript
2158+}
2159
2160=== added file 'debian/maas-region-controller.maas-region-celery.upstart'
2161--- debian/maas-region-controller.maas-region-celery.upstart 1970-01-01 00:00:00 +0000
2162+++ debian/maas-region-controller.maas-region-celery.upstart 2013-10-11 14:15:22 +0000
2163@@ -0,0 +1,26 @@
2164+# maas-celery - celery daemon for the region controller
2165+#
2166+# MAAS Region Controller Celery Daemon
2167+
2168+description "MAAS"
2169+author "Raphael Badin <raphael.badin@canonical.com>"
2170+
2171+start on filesystem and net-device-up and rabbitmq-server-running
2172+stop on runlevel [016]
2173+
2174+respawn
2175+
2176+env workers_user="maas_workers"
2177+env workers_pass=""
2178+env workers_vhost="/maas_workers"
2179+
2180+pre-start script
2181+ if ! /usr/sbin/rabbitmqctl list_user_permissions $workers_user 1>/dev/null 2>&1; then
2182+ workers_pass=`grep "maas_workers" /etc/maas/maas_local_celeryconfig.py | cut -d':' -f3 | cut -d'@' -f1`
2183+ /usr/sbin/rabbitmqctl add_user "$workers_user" "$workers_pass"
2184+ /usr/sbin/rabbitmqctl add_vhost "$workers_vhost"
2185+ /usr/sbin/rabbitmqctl set_permissions -p "$workers_vhost" "$workers_user" ".*" ".*" ".*"
2186+ fi
2187+end script
2188+
2189+exec /usr/sbin/maas-region-celeryd --logfile=/var/log/maas/celery-region.log --schedule=/var/lib/maas/celerybeat-region-schedule --user=maas --group=maas
2190
2191=== added file 'debian/maas-region-controller.maas-txlongpoll.upstart'
2192--- debian/maas-region-controller.maas-txlongpoll.upstart 1970-01-01 00:00:00 +0000
2193+++ debian/maas-region-controller.maas-txlongpoll.upstart 2013-10-11 14:15:22 +0000
2194@@ -0,0 +1,27 @@
2195+# maas - txlongpoll service
2196+#
2197+# MAAS Provisioning Service txlongpoll
2198+
2199+description "MAAS txlongpoll"
2200+author "Andres Rodriguez <andres.rodriguez@canonical.com>"
2201+
2202+start on filesystem and net-device-up and rabbitmq-server-running
2203+stop on runlevel [016]
2204+
2205+respawn
2206+
2207+env longpoll_user="maas_longpoll"
2208+env longpoll_pass=""
2209+env longpoll_vhost="/maas_longpoll"
2210+
2211+pre-start script
2212+ if ! /usr/sbin/rabbitmqctl list_user_permissions $longpoll_user 1>/dev/null 2>&1; then
2213+ longpoll_pass=`/bin/grep "password" /etc/maas/txlongpoll.yaml | cut -d'"' -f2`
2214+ /usr/sbin/rabbitmqctl add_user "$longpoll_user" "$longpoll_pass"
2215+ /usr/sbin/rabbitmqctl add_vhost "$longpoll_vhost"
2216+ /usr/sbin/rabbitmqctl set_permissions -p "$longpoll_vhost" "$longpoll_user" ".*" ".*" ".*"
2217+ fi
2218+end script
2219+
2220+# To add options to your daemon, edit the line below:
2221+exec /usr/bin/twistd -n --uid=maas --gid=maas --pidfile=/run/maas-txlongpoll.pid --logfile=/dev/null txlongpoll --config-file=/etc/maas/txlongpoll.yaml
2222
2223=== added file 'debian/maas-region-controller.postinst'
2224--- debian/maas-region-controller.postinst 1970-01-01 00:00:00 +0000
2225+++ debian/maas-region-controller.postinst 2013-10-11 14:15:22 +0000
2226@@ -0,0 +1,287 @@
2227+#!/bin/sh
2228+
2229+set -e
2230+
2231+. /usr/share/debconf/confmodule
2232+db_version 2.0
2233+
2234+if [ -f /usr/share/dbconfig-common/dpkg/postinst.pgsql ]; then
2235+ . /usr/share/dbconfig-common/dpkg/postinst.pgsql
2236+fi
2237+
2238+RELEASE=`lsb_release -rs` || RELEASE=""
2239+
2240+maas_sync_migrate_db(){
2241+ maas syncdb --noinput
2242+ maas migrate maasserver --noinput
2243+ maas migrate metadataserver --noinput
2244+}
2245+
2246+restart_rabbitmq(){
2247+ invoke-rc.d rabbitmq-server restart || true
2248+}
2249+
2250+restart_postgresql(){
2251+ invoke-rc.d --force postgresql restart || true
2252+}
2253+
2254+restart_squid_deb_proxy() {
2255+ invoke-rc.d squid-deb-proxy restart || true
2256+}
2257+
2258+configure_region_http() {
2259+ case $RELEASE in
2260+ 12.04|12.10|13.04)
2261+ # handle apache configs
2262+ if [ -e /etc/maas/maas-http.conf -a \
2263+ ! -e /etc/apache2/conf.d/maas-http.conf ]; then
2264+ ln -sf /etc/maas/maas-http.conf /etc/apache2/conf.d/maas-http.conf
2265+ fi
2266+ ;;
2267+ *)
2268+ # handle apache configs
2269+ if [ -e /etc/maas/maas-http.conf -a \
2270+ ! -e /etc/apache2/conf-enabled/maas-http.conf ]; then
2271+ ln -sf /etc/maas/maas-http.conf /etc/apache2/conf-enabled/maas-http.conf
2272+ fi
2273+ ;;
2274+ esac
2275+ # enable apache modules needed
2276+ a2enmod proxy_http
2277+ a2enmod expires
2278+ a2enmod wsgi
2279+}
2280+
2281+configure_maas_txlongpoll_rabbitmq_user() {
2282+ local longpoll_user="maas_longpoll"
2283+ local longpoll_pass=
2284+ local longpoll_vhost="/maas_longpoll"
2285+ longpoll_pass="$(pwgen -s 20)"
2286+ if [ -x /usr/sbin/rabbitmqctl ]; then
2287+ if ! rabbitmqctl list_users | grep -qs "$longpoll_user"; then
2288+ rabbitmqctl add_user "$longpoll_user" "$longpoll_pass" || true
2289+ rabbitmqctl add_vhost "$longpoll_vhost" || true
2290+ rabbitmqctl set_permissions -p "$longpoll_vhost" "$longpoll_user" ".*" ".*" ".*" || true
2291+ else
2292+ rabbitmqctl change_password "$longpoll_user" "$longpoll_pass" || true
2293+ fi
2294+ fi
2295+
2296+ if grep -qs "^\ \{1,\}password: \"[a-zA-Z0-9]\{0,\}\"$" /etc/maas/txlongpoll.yaml; then
2297+ sed -i "s/^\ \{1,\}password: \"[a-zA-Z0-9]\{0,\}\"$/ password: \""$longpoll_pass"\"/" \
2298+ /etc/maas/txlongpoll.yaml
2299+ fi
2300+ if grep -qs "^RABBITMQ_PASSWORD\ \= '[a-zA-Z0-9]\{0,\}'$" /etc/maas/maas_local_settings.py; then
2301+ sed -i "s/^RABBITMQ_PASSWORD\ \= '[a-zA-Z0-9]\{0,\}'$/RABBITMQ_PASSWORD = '"$longpoll_pass"'/" \
2302+ /etc/maas/maas_local_settings.py
2303+ fi
2304+}
2305+
2306+configure_maas_workers_rabbitmq_user() {
2307+ local workers_user="maas_workers"
2308+ local workers_pass="$(pwgen -s 20)"
2309+ local workers_vhost="/maas_workers"
2310+ local amqp_host="$1"
2311+ if [ -z "$amqp_host" ]; then
2312+ amqp_host="localhost"
2313+ fi
2314+ local amqp_port="5672"
2315+ if [ -x /usr/sbin/rabbitmqctl ]; then
2316+ if ! rabbitmqctl list_users | grep -qs "$workers_user"; then
2317+ rabbitmqctl add_user "$workers_user" "$workers_pass" || true
2318+ rabbitmqctl add_vhost "$workers_vhost" || true
2319+ rabbitmqctl set_permissions -p "$workers_vhost" "$workers_user" ".*" ".*" ".*" || true
2320+ else
2321+ rabbitmqctl change_password "$workers_user" "$workers_pass" || true
2322+ fi
2323+ fi
2324+
2325+ if grep -qs "^BROKER_URL\ \= '.*'$" /etc/maas/maas_local_celeryconfig.py; then
2326+ local broker_url="amqp://$workers_user:$workers_pass@$amqp_host:$amqp_port/$workers_vhost"
2327+ sed -i "s|^BROKER_URL\ \= '.*'$|BROKER_URL = '"$broker_url"'|" \
2328+ /etc/maas/maas_local_celeryconfig.py
2329+ fi
2330+}
2331+
2332+configure_maas_database() {
2333+ local dbc_dbpass="$1"
2334+ if grep -qs "^\ \{1,\} 'PASSWORD': '[a-zA-Z0-9]\{0,\}',$" /etc/maas/maas_local_settings.py; then
2335+ sed -i "s/^\ \{1,\} 'PASSWORD': '[a-zA-Z0-9]\{0,\}',$/ 'PASSWORD': '"$dbc_dbpass"',/" \
2336+ /etc/maas/maas_local_settings.py
2337+ fi
2338+}
2339+
2340+configure_maas_default_url() {
2341+ local ipaddr="$1"
2342+
2343+ if grep -qs "^DEFAULT_MAAS_URL\ \= \"[a-zA-Z0-9:/.]\{0,\}\"$" /etc/maas/maas_local_settings.py; then
2344+ sed -i "s/^DEFAULT_MAAS_URL\ \= \"[a-zA-Z0-9:/.]\{0,\}\"$/DEFAULT_MAAS_URL = \"http:\/\/"$ipaddr"\/MAAS\"/" \
2345+ /etc/maas/maas_local_settings.py
2346+ fi
2347+}
2348+
2349+configure_maas_squid_deb_proxy() {
2350+ local ipaddr="$1"
2351+
2352+ if [ -e /usr/share/maas/conf/99-maas -a \
2353+ ! -L /etc/squid-deb-proxy/mirror-dstdomain.acl.d/99-maas ]; then
2354+ ln -sf /usr/share/maas/conf/99-maas \
2355+ /etc/squid-deb-proxy/mirror-dstdomain.acl.d/99-maas
2356+ fi
2357+
2358+ sed -i "s/\(^[a-zA-Z0-9\.\-].*\) # maasurl$/$ipaddr # maasurl/" \
2359+ /usr/share/maas/conf/99-maas
2360+}
2361+
2362+if [ "$1" = "configure" ] && [ -z "$2" ]; then
2363+ #########################################################
2364+ ################ Folder Permissions ####################
2365+ #########################################################
2366+ mkdir -p /var/lib/maas/media/storage
2367+ chown -R maas:maas /var/lib/maas/
2368+
2369+ # Config will contain credentials, so should be readable
2370+ # by the application but nobody else.
2371+ chown root:maas \
2372+ /etc/maas/maas_local_celeryconfig.py \
2373+ /etc/maas/maas_local_settings.py
2374+ chmod 0640 \
2375+ /etc/maas/maas_local_celeryconfig.py \
2376+ /etc/maas/maas_local_settings.py
2377+
2378+ #########################################################
2379+ ################ Configure Apache2 ####################
2380+ #########################################################
2381+ configure_region_http
2382+
2383+ #########################################################
2384+ ########## Configure DEFAULT_MAAS_URL #################
2385+ #########################################################
2386+
2387+ # Obtain IP address of default route and change DEFAULT_MAAS_URL.
2388+ while read Iface Destination Gateway Flags RefCnt Use Metric Mask MTU Window IRTT; do
2389+ [ "$Mask" = "00000000" ] && break
2390+ done < /proc/net/route
2391+ interface="$Iface"
2392+ ipaddr=$(LC_ALL=C /sbin/ip -4 addr list dev "$interface" scope global)
2393+ ipaddr=${ipaddr#* inet }
2394+ ipaddr=${ipaddr%%/*}
2395+ # Set the IP address of the interface with default route
2396+ if [ -n "$ipaddr" ]; then
2397+ configure_maas_default_url "$ipaddr"
2398+ configure_maas_squid_deb_proxy "$ipaddr"
2399+ db_subst maas/installation-note MAAS_URL "$ipaddr"
2400+ db_set maas/default-maas-url "$ipaddr"
2401+ fi
2402+
2403+ #########################################################
2404+ ################ Configure Logging ####################
2405+ #########################################################
2406+
2407+ # Give appropriate permissions
2408+ if [ ! -f /var/log/maas/maas.log ]; then
2409+ touch /var/log/maas/maas.log
2410+ fi
2411+ chown -R maas:maas /var/log/maas
2412+ chmod -R 775 /var/log/maas/oops
2413+
2414+ # Create log directory base
2415+ mkdir -p /var/log/maas/rsyslog
2416+ chown -R syslog:syslog /var/log/maas/rsyslog
2417+ # Make sure rsyslog reads our config
2418+ invoke-rc.d rsyslog restart
2419+
2420+ #########################################################
2421+ ################### Squid-deb-proxy ####################
2422+ #########################################################
2423+ # Make sure squid-deb-proxy reads our config (99-maas)
2424+ invoke-rc.d squid-deb-proxy restart
2425+
2426+ #########################################################
2427+ ########## Configure longpoll rabbitmq config ###########
2428+ #########################################################
2429+
2430+ # Handle longpoll/rabbitmq publishing
2431+ restart_rabbitmq
2432+ configure_maas_txlongpoll_rabbitmq_user
2433+
2434+ #########################################################
2435+ ########## Configure worker rabbitmq config ###########
2436+ #########################################################
2437+
2438+ # Handle celery/rabbitmq publishing
2439+ configure_maas_workers_rabbitmq_user "$ipaddr"
2440+
2441+ #########################################################
2442+ ################ Configure Database ###################
2443+ #########################################################
2444+
2445+ # Need to for postgresql start so it doesn't fail on the installer
2446+ restart_postgresql
2447+
2448+ # Create the database
2449+ dbc_go maas-region-controller $@
2450+ configure_maas_database "$dbc_dbpass"
2451+
2452+ # Only syncdb if we have selected to install it with dbconfig-common.
2453+ db_get maas-region-controller/dbconfig-install
2454+ if [ "$RET" = "true" ]; then
2455+ maas_sync_migrate_db
2456+ fi
2457+
2458+ # Display installation note
2459+ db_input high maas/installation-note || true
2460+ db_go
2461+
2462+elif [ -n "$DEBCONF_RECONFIGURE" ]; then
2463+ # Set the IP address of the interface with default route
2464+ db_get maas/default-maas-url
2465+ ipaddr="$RET"
2466+ if [ -n "$ipaddr" ]; then
2467+ configure_maas_default_url "$ipaddr"
2468+ configure_maas_squid_deb_proxy "$ipaddr"
2469+ configure_maas_workers_rabbitmq_user "$ipaddr"
2470+ fi
2471+
2472+elif [ "$1" = "configure" ] && dpkg --compare-versions "$2" gt 0.1+bzr266+dfsg-0ubuntu1; then
2473+ # If upgrading to any later package version, then upgrade db.
2474+ invoke-rc.d apache2 stop || true
2475+
2476+ # make sure postgresql is running
2477+ restart_postgresql
2478+
2479+ # make sure maas http config is symlinked
2480+ configure_region_http
2481+
2482+ # we need to regenerate the passwords and update configs.
2483+ db_get maas/default-maas-url
2484+ ipaddr="$RET"
2485+ configure_maas_default_url "$ipaddr"
2486+ configure_maas_squid_deb_proxy "$ipaddr"
2487+ # make sure rabbitmq is running
2488+ restart_rabbitmq
2489+ configure_maas_txlongpoll_rabbitmq_user
2490+ # Handle celery/rabbitmq publishing
2491+ configure_maas_workers_rabbitmq_user "$ipaddr"
2492+ # handle database upgrade
2493+ if [ -f /etc/dbconfig-common/maas-region-controller.conf ]; then
2494+ # source dbconfig-common db config for maas-region-controller
2495+ # before upgrading database, otherwise a new config is written
2496+ # but the password is no longer preserved.
2497+ . /etc/dbconfig-common/maas-region-controller.conf
2498+ else
2499+ dbc_go maas-region-controller $@
2500+ fi
2501+ configure_maas_database "$dbc_dbpass"
2502+
2503+ maas_sync_migrate_db
2504+
2505+fi
2506+
2507+invoke-rc.d apache2 restart || true
2508+
2509+restart_squid_deb_proxy
2510+
2511+db_stop
2512+
2513+#DEBHELPER#
2514
2515=== added file 'debian/maas-region-controller.postrm'
2516--- debian/maas-region-controller.postrm 1970-01-01 00:00:00 +0000
2517+++ debian/maas-region-controller.postrm 2013-10-11 14:15:22 +0000
2518@@ -0,0 +1,59 @@
2519+#!/bin/sh
2520+
2521+set -e
2522+
2523+. /usr/share/debconf/confmodule
2524+
2525+RELEASE=`lsb_release -rs` || RELEASE=""
2526+
2527+if [ -f /etc/dbconfig-common/maas.conf ]; then
2528+ if [ -f /usr/share/dbconfig-common/dpkg/postrm ]; then
2529+ . /usr/share/dbconfig-common/dpkg/postrm.pgsql
2530+ dbc_go maas-region-controller $@
2531+ fi
2532+fi
2533+
2534+case "$1" in
2535+ purge)
2536+ rm -rf /var/log/maas
2537+ rm -rf /var/lib/maas
2538+ case $RELEASE in
2539+ 12.04|12.10|13.04)
2540+ if [ -h /etc/apache2/conf.d/maas-http.conf ]; then
2541+ rm -rf /etc/apache2/conf.d/maas-http.conf
2542+ fi
2543+ ;;
2544+ *)
2545+ if [ -h /etc/apache2/conf-enabled/maas-http.conf ]; then
2546+ rm -rf /etc/apache2/conf-enabled/maas-http.conf
2547+ fi
2548+ ;;
2549+ esac
2550+
2551+ # Restarting apache2
2552+ if [ -x /usr/sbin/invoke-rc.d ]; then
2553+ invoke-rc.d apache2 restart || true
2554+ fi
2555+
2556+ # Delete symlink
2557+ if [ -L /etc/squid-deb-proxy/mirror-dstdomain.acl.d/99-maas ]; then
2558+ rm -rf /etc/squid-deb-proxy/mirror-dstdomain.acl.d/99-maas
2559+ fi
2560+
2561+ # Remove rabbitmq/longpoll/celery
2562+ longpoll_user="maas_longpoll"
2563+ longpoll_vhost="/maas_longpoll"
2564+ workers_user="maas_workers"
2565+ workers_vhost="/maas_workers"
2566+ if [ -x /usr/sbin/rabbitmqctl ]; then
2567+ rabbitmqctl delete_vhost "$longpoll_vhost" || true
2568+ rabbitmqctl delete_user "$longpoll_user" || true
2569+
2570+ rabbitmqctl delete_vhost "$workers_vhost" || true
2571+ rabbitmqctl delete_user "$workers_user" || true
2572+ fi
2573+esac
2574+
2575+#DEBHELPER#
2576+
2577+db_stop
2578
2579=== added file 'debian/maas-region-controller.prerm'
2580--- debian/maas-region-controller.prerm 1970-01-01 00:00:00 +0000
2581+++ debian/maas-region-controller.prerm 2013-10-11 14:15:22 +0000
2582@@ -0,0 +1,12 @@
2583+#!/bin/sh
2584+
2585+set -e
2586+
2587+. /usr/share/debconf/confmodule
2588+
2589+#DEBHELPER#
2590+
2591+invoke-rc.d apache2 stop || true
2592+
2593+. /usr/share/dbconfig-common/dpkg/prerm.pgsql
2594+dbc_go maas-region-controller $@
2595
2596=== added file 'debian/maas-region-controller.templates'
2597--- debian/maas-region-controller.templates 1970-01-01 00:00:00 +0000
2598+++ debian/maas-region-controller.templates 2013-10-11 14:15:22 +0000
2599@@ -0,0 +1,22 @@
2600+Template: maas/installation-note
2601+Type: note
2602+Default: true
2603+_Description: Ubuntu MAAS Server
2604+ The Ubuntu MAAS Server has been installed in your system. You
2605+ can access the MAAS Web interface here:
2606+ .
2607+ http://${MAAS_URL}/MAAS
2608+ .
2609+ If the automatically detected address above is not in the same
2610+ network as the MAAS clients, you need to reconfigure it:
2611+ .
2612+ sudo dpkg-reconfigure maas-region-controller
2613+
2614+Template: maas/default-maas-url
2615+Type: string
2616+_Description: Ubuntu MAAS PXE/Provisioning network address:
2617+ The Ubuntu MAAS Server automatically detects the IP address
2618+ that is used for PXE and provisioning. However, it needs to be
2619+ in the same network as the clients. If the automatically
2620+ detected address is not in the same network as the clients, it
2621+ must be changed.
2622
2623=== added file 'debian/maintscript'
2624--- debian/maintscript 1970-01-01 00:00:00 +0000
2625+++ debian/maintscript 2013-10-11 14:15:22 +0000
2626@@ -0,0 +1,2 @@
2627+rm_conffile /etc/init/maas-celery.conf 0.1+bzr971+dfsg-0ubuntu2
2628+rm_conffile /etc/dbconfig-common/maas.conf 0.1+bzr971+dfsg-0ubuntu2
2629
2630=== added directory 'debian/patches'
2631=== added file 'debian/patches/01-fix-database-settings.patch'
2632--- debian/patches/01-fix-database-settings.patch 1970-01-01 00:00:00 +0000
2633+++ debian/patches/01-fix-database-settings.patch 2013-10-11 14:15:22 +0000
2634@@ -0,0 +1,26 @@
2635+Index: maas-0.1+bzr702+dfsg.orig/contrib/maas_local_settings.py
2636+===================================================================
2637+--- maas-0.1+bzr702+dfsg.orig.orig/contrib/maas_local_settings.py 2012-06-29 12:03:20.000000000 -0400
2638++++ maas-0.1+bzr702+dfsg.orig/contrib/maas_local_settings.py 2012-06-29 12:17:00.733389757 -0400
2639+@@ -7,7 +7,7 @@
2640+ DEFAULT_MAAS_URL = "http://maas.internal.example.com/"
2641+
2642+ # Absolute path to the directory static files should be collected to.
2643+-STATIC_ROOT = '/var/lib/maas/static/'
2644++STATIC_ROOT = '/usr/share/maas/web/static/'
2645+
2646+ # Prefix to use for MAAS's urls.
2647+ # If FORCE_SCRIPT_NAME is None (the default), all the urls will start with
2648+@@ -68,9 +68,9 @@
2649+ 'default': {
2650+ # 'postgresql_psycopg2', 'postgresql', 'mysql', 'sqlite3' etc.
2651+ 'ENGINE': 'django.db.backends.postgresql_psycopg2',
2652+- 'NAME': '',
2653+- 'USER': '',
2654+- 'PASSWORD': '',
2655++ 'NAME': 'maasdb',
2656++ 'USER': 'maas',
2657++ 'PASSWORD': 'maas',
2658+ 'HOST': 'localhost',
2659+ }
2660+ }
2661
2662=== added file 'debian/patches/02-pserv-config.patch'
2663--- debian/patches/02-pserv-config.patch 1970-01-01 00:00:00 +0000
2664+++ debian/patches/02-pserv-config.patch 2013-10-11 14:15:22 +0000
2665@@ -0,0 +1,38 @@
2666+Description: Use default settings for MAAS PSERV
2667+ Use default settings for MAAS pserv. These default settings
2668+ include port, logfile, oops directory, cobbler url and username
2669+Author: Andres Rodriguez <andreserl@ubuntu.com>
2670+
2671+Index: maas-0.1+bzr917+dfsg.orig/etc/maas/pserv.yaml
2672+===================================================================
2673+--- maas-0.1+bzr917+dfsg.orig.orig/etc/maas/pserv.yaml 2012-08-23 16:22:46.483599114 -0400
2674++++ maas-0.1+bzr917+dfsg.orig/etc/maas/pserv.yaml 2012-08-23 16:22:56.579599373 -0400
2675+@@ -6,7 +6,7 @@
2676+ ## running server.
2677+ #
2678+ # logfile: "pserv.log"
2679+-logfile: "/dev/null"
2680++logfile: "/var/log/maas/pserv.log"
2681+
2682+ ## OOPS configuration (optional).
2683+ #
2684+@@ -15,7 +15,7 @@
2685+ # or directories other than what the oops machinery creates there.
2686+ #
2687+ # directory:
2688+- directory: "logs/oops"
2689++ directory: "/var/log/maas/oops"
2690+ # reporter:
2691+ reporter: "maas-pserv"
2692+
2693+@@ -33,10 +33,8 @@
2694+ tftp:
2695+ # root: /var/lib/maas/tftp
2696+ # port: 69
2697+- port: 5244
2698+ ## The URL to be contacted to generate PXE configurations.
2699+ # generator: http://localhost/MAAS/api/1.0/pxeconfig/
2700+- generator: http://localhost:5243/api/1.0/pxeconfig/
2701+
2702+ ## Boot configuration.
2703+ boot:
2704
2705=== added file 'debian/patches/03-txlongpoll-config.patch'
2706--- debian/patches/03-txlongpoll-config.patch 1970-01-01 00:00:00 +0000
2707+++ debian/patches/03-txlongpoll-config.patch 2013-10-11 14:15:22 +0000
2708@@ -0,0 +1,39 @@
2709+Description: Use default settings for MAAS txlongpoll
2710+ Use default settings for MAAS txlongpoll. These default settings
2711+ include oops directory, Message broker configuration, logfile.
2712+Author: Andres Rodriguez <andreserl@ubuntu.com>
2713+
2714+Index: maas-0.1+bzr398+dfsg.orig/etc/txlongpoll.yaml
2715+===================================================================
2716+--- maas-0.1+bzr398+dfsg.orig.orig/etc/txlongpoll.yaml 2012-04-03 09:49:48.109427702 -0400
2717++++ maas-0.1+bzr398+dfsg.orig/etc/txlongpoll.yaml 2012-04-03 09:53:07.276282800 -0400
2718+@@ -17,7 +17,7 @@
2719+ # or directories other than what the oops machinery creates there.
2720+ #
2721+ # directory: ""
2722+- directory: "logs/oops"
2723++ directory: "/var/log/maas/oops"
2724+ ## The reporter used when generating OOPS reports.
2725+ # reporter: "LONGPOLL"
2726+ reporter: "maas-txlongpoll"
2727+@@ -25,14 +25,14 @@
2728+ ## Message broker configuration.
2729+ #
2730+ broker:
2731+- # host: "localhost"
2732+- # port: 5672
2733+- # username: "guest"
2734+- # password: "guest"
2735+- # vhost: "/"
2736++ host: "localhost"
2737++ port: 5672
2738++ username: "maas_longpoll"
2739++ password: "maaslongpoll"
2740++ vhost: "/maas_longpoll"
2741+
2742+ ## Where to log. This log can be rotated by sending SIGUSR1 to the
2743+ ## running server.
2744+ #
2745+ # logfile: "txlongpoll.log"
2746+-logfile: "/dev/null"
2747++logfile: "/var/log/maas/txlongpoll.log"
2748
2749=== added file 'debian/patches/series'
2750--- debian/patches/series 1970-01-01 00:00:00 +0000
2751+++ debian/patches/series 2013-10-11 14:15:22 +0000
2752@@ -0,0 +1,3 @@
2753+01-fix-database-settings.patch
2754+02-pserv-config.patch
2755+03-txlongpoll-config.patch
2756
2757=== added directory 'debian/po'
2758=== added file 'debian/po/POTFILES.in'
2759--- debian/po/POTFILES.in 1970-01-01 00:00:00 +0000
2760+++ debian/po/POTFILES.in 2013-10-11 14:15:22 +0000
2761@@ -0,0 +1,2 @@
2762+[type: gettext/rfc822deb] maas-region-controller.templates
2763+[type: gettext/rfc822deb] maas-cluster-controller.templates
2764
2765=== added file 'debian/po/templates.pot'
2766--- debian/po/templates.pot 1970-01-01 00:00:00 +0000
2767+++ debian/po/templates.pot 2013-10-11 14:15:22 +0000
2768@@ -0,0 +1,82 @@
2769+# SOME DESCRIPTIVE TITLE.
2770+# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
2771+# This file is distributed under the same license as the PACKAGE package.
2772+# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
2773+#
2774+#, fuzzy
2775+msgid ""
2776+msgstr ""
2777+"Project-Id-Version: maas\n"
2778+"Report-Msgid-Bugs-To: maas@packages.debian.org\n"
2779+"POT-Creation-Date: 2012-10-04 13:40-0400\n"
2780+"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
2781+"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
2782+"Language-Team: LANGUAGE <LL@li.org>\n"
2783+"Language: \n"
2784+"MIME-Version: 1.0\n"
2785+"Content-Type: text/plain; charset=CHARSET\n"
2786+"Content-Transfer-Encoding: 8bit\n"
2787+
2788+#. Type: note
2789+#. Description
2790+#: ../maas-region-controller.templates:1001
2791+msgid "Ubuntu MAAS Server"
2792+msgstr ""
2793+
2794+#. Type: note
2795+#. Description
2796+#: ../maas-region-controller.templates:1001
2797+msgid ""
2798+"The Ubuntu MAAS Server has been installed in your system. You can access the "
2799+"MAAS Web interface here:"
2800+msgstr ""
2801+
2802+#. Type: note
2803+#. Description
2804+#: ../maas-region-controller.templates:1001
2805+msgid " http://${MAAS_URL}/MAAS"
2806+msgstr ""
2807+
2808+#. Type: note
2809+#. Description
2810+#: ../maas-region-controller.templates:1001
2811+msgid ""
2812+"If the automatically detected address above is not in the same network as "
2813+"the MAAS clients, you need to reconfigure it:"
2814+msgstr ""
2815+
2816+#. Type: note
2817+#. Description
2818+#: ../maas-region-controller.templates:1001
2819+msgid " sudo dpkg-reconfigure maas-region-controller"
2820+msgstr ""
2821+
2822+#. Type: string
2823+#. Description
2824+#: ../maas-region-controller.templates:2001
2825+msgid "Ubuntu MAAS PXE/Provisioning network address:"
2826+msgstr ""
2827+
2828+#. Type: string
2829+#. Description
2830+#: ../maas-region-controller.templates:2001
2831+msgid ""
2832+"The Ubuntu MAAS Server automatically detects the IP address that is used for "
2833+"PXE and provisioning. However, it needs to be in the same network as the "
2834+"clients. If the automatically detected address is not in the same network as "
2835+"the clients, it must be changed."
2836+msgstr ""
2837+
2838+#. Type: string
2839+#. Description
2840+#: ../maas-cluster-controller.templates:1001
2841+msgid "Ubuntu MAAS API address:"
2842+msgstr ""
2843+
2844+#. Type: string
2845+#. Description
2846+#: ../maas-cluster-controller.templates:1001
2847+msgid ""
2848+"The MAAS Cluster Controller needs to contact the MAAS server to register its "
2849+"presence. Set the URL to the MAAS API here, e.g. http://192.168.1.1/MAAS"
2850+msgstr ""
2851
2852=== added file 'debian/python-django-maas.install'
2853--- debian/python-django-maas.install 1970-01-01 00:00:00 +0000
2854+++ debian/python-django-maas.install 2013-10-11 14:15:22 +0000
2855@@ -0,0 +1,2 @@
2856+debian/tmp/usr/lib/python*/dist-packages/maasserver
2857+debian/tmp/usr/lib/python*/dist-packages/metadataserver
2858
2859=== added file 'debian/python-maas-client.install'
2860--- debian/python-maas-client.install 1970-01-01 00:00:00 +0000
2861+++ debian/python-maas-client.install 2013-10-11 14:15:22 +0000
2862@@ -0,0 +1,1 @@
2863+debian/tmp/usr/lib/python*/dist-packages/apiclient
2864
2865=== added file 'debian/python-maas-provisioningserver.install'
2866--- debian/python-maas-provisioningserver.install 1970-01-01 00:00:00 +0000
2867+++ debian/python-maas-provisioningserver.install 2013-10-11 14:15:22 +0000
2868@@ -0,0 +1,4 @@
2869+debian/tmp/usr/lib/python*/dist-packages/provisioningserver
2870+
2871+# Install other stuff
2872+debian/extras/maas-provision usr/sbin
2873
2874=== added file 'debian/python-maas-provisioningserver.lintian-overrides'
2875--- debian/python-maas-provisioningserver.lintian-overrides 1970-01-01 00:00:00 +0000
2876+++ debian/python-maas-provisioningserver.lintian-overrides 2013-10-11 14:15:22 +0000
2877@@ -0,0 +1,1 @@
2878+python-maas-provisioningserver: binary-without-manpage usr/sbin/maas-provision
2879
2880=== added file 'debian/rules'
2881--- debian/rules 1970-01-01 00:00:00 +0000
2882+++ debian/rules 2013-10-11 14:15:22 +0000
2883@@ -0,0 +1,65 @@
2884+#!/usr/bin/make -f
2885+
2886+BUILDHOME = $(CURDIR)/debian/build
2887+PYTHON = $(shell pyversions -d)
2888+# Python enum modules.
2889+py_enums := $(wildcard src/*/enum.py)
2890+
2891+%:
2892+ dh $@ --with python2,apport --buildsystem=python_distutils
2893+
2894+override_dh_installinit:
2895+ dh_installinit --name maas-pserv
2896+ dh_installinit --name maas-txlongpoll
2897+ dh_installinit --name maas-region-celery
2898+ dh_installinit --name maas-cluster-celery
2899+ dh_installinit --name maas-dhcp-server
2900+
2901+override_dh_auto_build:
2902+ dh_auto_build
2903+
2904+ mkdir -p $(BUILDHOME)
2905+ HOME=$(BUILDHOME) PYTHONPATH=$(CURDIR)/src/ $(PYTHON) \
2906+ $(CURDIR)/src/maasserver/utils/jsenums.py \
2907+ $(py_enums) > $(BUILDHOME)/enums.js
2908+
2909+override_dh_auto_install:
2910+ dh_auto_install
2911+
2912+ # Move static files
2913+ install -d -m 755 $(CURDIR)/debian/tmp/usr/share/maas/web/static
2914+ mv $(CURDIR)/debian/tmp/usr/lib/python*/*-packages/maasserver/static \
2915+ $(CURDIR)/debian/tmp/usr/share/maas/web/
2916+
2917+ # Install built enums.js file.
2918+ cp $(BUILDHOME)/enums.js $(CURDIR)/debian/tmp/usr/share/maas/web/static/js/
2919+
2920+ # install the apparmor profile
2921+ install -d -m 755 $(CURDIR)/debian/tmp/etc/apparmor.d/dhcpd.d
2922+ install -m 644 $(CURDIR)/debian/maas-dhcp.apparmor \
2923+ $(CURDIR)/debian/tmp/etc/apparmor.d/dhcpd.d/maas
2924+
2925+ dh_install --list-missing
2926+
2927+override_dh_auto_clean:
2928+ dh_auto_clean
2929+ rm -rf $(BUILDHOME)
2930+ rm -rf src/*.egg-info
2931+
2932+DEB_DEBIAN_DIR=$(dir $(firstword $(MAKEFILE_LIST)))
2933+REV=$(shell dpkg-parsechangelog -l$(DEB_DEBIAN_DIR)/changelog \
2934+ | sed -rne 's,^Version: .*[+~]bzr([0-9]+).*,\1,p')
2935+VER=$(shell dpkg-parsechangelog -l$(DEB_DEBIAN_DIR)/changelog \
2936+ | sed -rne 's,^Version: ([^-]+).*,\1,p')
2937+get-orig-source:
2938+ bzr export -r $(REV) --root=maas-$(VER).orig \
2939+ maas_$(VER).orig.tar.gz lp:maas
2940+ rm -rf maas-$(VER)
2941+ tar -xf maas_$(VER).orig.tar.gz
2942+ rm maas_$(VER).orig.tar.gz
2943+ rm -rf maas-$(VER).orig/src/maasserver/static/jslibs/
2944+ rm -rf maas-$(VER).orig/contrib/python-tx-tftp
2945+ GZIP=--best tar -cz --owner root --group root --mode a+rX \
2946+ -f maas_$(VER).orig.tar.gz \
2947+ maas-$(VER).orig
2948+ rm -r maas-$(VER).orig
2949
2950=== added directory 'debian/source'
2951=== added file 'debian/source/format'
2952--- debian/source/format 1970-01-01 00:00:00 +0000
2953+++ debian/source/format 2013-10-11 14:15:22 +0000
2954@@ -0,0 +1,1 @@
2955+3.0 (quilt)
2956
2957=== added file 'debian/watch'
2958--- debian/watch 1970-01-01 00:00:00 +0000
2959+++ debian/watch 2013-10-11 14:15:22 +0000
2960@@ -0,0 +1,3 @@
2961+version=3
2962+opts=dversionmangle=s/\.dfsg// \
2963+http://launchpad.net/maas/+download https://launchpad.net/maas/.*/maas-(.*).tar.*