Merge lp:~harmw/cloud-init/freebsd-fixes into lp:~cloud-init-dev/cloud-init/trunk

Proposed by Harm Weites
Status: Merged
Merged at revision: 1006
Proposed branch: lp:~harmw/cloud-init/freebsd-fixes
Merge into: lp:~cloud-init-dev/cloud-init/trunk
Diff against target: 34 lines (+2/-4)
2 files modified
cloudinit/distros/freebsd.py (+1/-4)
tools/build-on-freebsd (+1/-0)
To merge this branch: bzr merge lp:~harmw/cloud-init/freebsd-fixes
Reviewer Review Type Date Requested Status
Scott Moser Pending
Review via email: mp+233247@code.launchpad.net

Description of the change

Use the regular logic to create sudo rules and just supply the correct filename. The temp script in tools/ should install 2 more dependencies, so make it do that.

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=== modified file 'cloudinit/distros/freebsd.py'
2--- cloudinit/distros/freebsd.py 2014-08-28 17:54:00 +0000
3+++ cloudinit/distros/freebsd.py 2014-09-03 17:23:52 +0000
4@@ -37,6 +37,7 @@
5 login_conf_fn = '/etc/login.conf'
6 login_conf_fn_bak = '/etc/login.conf.orig'
7 resolv_conf_fn = '/etc/resolv.conf'
8+ ci_sudoers_fn = '/usr/local/etc/sudoers.d/90-cloud-init-users'
9
10 def __init__(self, name, cfg, paths):
11 distros.Distro.__init__(self, name, cfg, paths)
12@@ -219,10 +220,6 @@
13 util.logexc(LOG, "Failed to lock user %s", name)
14 raise e
15
16- # TODO:
17- def write_sudo_rules(self, name, rules, sudo_file=None):
18- LOG.debug("[write_sudo_rules] Name: %s", name)
19-
20 def create_user(self, name, **kwargs):
21 self.add_user(name, **kwargs)
22
23
24=== modified file 'tools/build-on-freebsd'
25--- tools/build-on-freebsd 2014-08-23 12:16:03 +0000
26+++ tools/build-on-freebsd 2014-09-03 17:23:52 +0000
27@@ -17,6 +17,7 @@
28 py27-prettytable
29 py27-requests py27-six
30 python py27-cheetah
31+ py27-jsonpointer py27-jsonpatch
32 "
33 [ -f "$depschecked" ] || pkg install ${pkgs} || fail "install packages"
34 touch $depschecked