Merge lp:~joetalbott/charms/trusty/snappy-proposed-image-builder/fix_user_info into lp:~canonical-ci-engineering/charms/trusty/snappy-proposed-image-builder/trunk

Proposed by Joe Talbott
Status: Merged
Approved by: Joe Talbott
Approved revision: 11
Merged at revision: 11
Proposed branch: lp:~joetalbott/charms/trusty/snappy-proposed-image-builder/fix_user_info
Merge into: lp:~canonical-ci-engineering/charms/trusty/snappy-proposed-image-builder/trunk
Diff against target: 12 lines (+1/-1)
1 file modified
hooks/actions.py (+1/-1)
To merge this branch: bzr merge lp:~joetalbott/charms/trusty/snappy-proposed-image-builder/fix_user_info
Reviewer Review Type Date Requested Status
Celso Providelo (community) Approve
Review via email: mp+261259@code.launchpad.net

Commit message

Fix user and group info accesses.

Description of the change

Fix user and group info accesses.

To post a comment you must log in.
Revision history for this message
Celso Providelo (cprov) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'hooks/actions.py'
--- hooks/actions.py 2015-06-04 21:59:21 +0000
+++ hooks/actions.py 2015-06-05 18:01:14 +0000
@@ -81,7 +81,7 @@
81 # make sure the user owns their home.81 # make sure the user owns their home.
82 group_info = grp.getgrnam(username)82 group_info = grp.getgrnam(username)
83 user_info = pwd.getpwnam(username)83 user_info = pwd.getpwnam(username)
84 os.chown(home, user_info['pw_uid'], group_info['gr_gid'])84 os.chown(home, user_info.pw_uid, group_info.gr_gid)
8585
8686
87def install_python_packages(service_name):87def install_python_packages(service_name):

Subscribers

People subscribed via source and target branches