Merge lp:~canonical-platform-qa/utah/tmpdir into lp:utah

Proposed by Max Brustkern
Status: Merged
Approved by: Max Brustkern
Approved revision: 1065
Merged at revision: 1065
Proposed branch: lp:~canonical-platform-qa/utah/tmpdir
Merge into: lp:utah
Diff against target: 12 lines (+1/-1)
1 file modified
utah/provisioning/vm.py (+1/-1)
To merge this branch: bzr merge lp:~canonical-platform-qa/utah/tmpdir
Reviewer Review Type Date Requested Status
Francis Ginther (community) Approve
Review via email: mp+272041@code.launchpad.net

Commit message

Changing tmpdir since apparmor now denies /tmp

Description of the change

This branch moves the VM temporary directory inside the VM directory since apparmor blocks /tmp access now.

To post a comment you must log in.
Revision history for this message
Francis Ginther (fginther) wrote :

Looks good.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'utah/provisioning/vm.py'
2--- utah/provisioning/vm.py 2014-08-12 14:27:10 +0000
3+++ utah/provisioning/vm.py 2015-09-22 22:05:31 +0000
4@@ -499,7 +499,7 @@
5 """
6 self.logger.info('Creating custom virtual machine')
7
8- tmpdir = tempfile.mkdtemp(prefix='/tmp/{}_'.format(self.name))
9+ tmpdir = tempfile.mkdtemp(prefix='{}/tmp'.format(self.directory))
10 self.cleanfile(tmpdir)
11 self.logger.debug('Working dir: %s', tmpdir)
12 os.chdir(tmpdir)

Subscribers

People subscribed via source and target branches