~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to bin/ivle-buildjail

  • Committer: William Grant
  • Date: 2009-05-31 01:32:39 UTC
  • mto: (1281.1.8 aufsless)
  • mto: This revision was merged to the branch mainline in revision 1300.
  • Revision ID: grantw@unimelb.edu.au-20090531013239-nixjhnprxe8cu1re
Replace /etc/passwd and /etc/ivle/ivle.conf in the jail with symlinks.

Show diffs side-by-side

added added

removed removed

Lines of Context:
142
142
    print >> sys.stderr, "Jail copying failed."
143
143
    sys.exit(1)
144
144
 
 
145
# Now mangle things a bit, so we can bind-mount the user bits in.
 
146
# /etc/passwd and /etc/ivle/ivle.conf need to be symlinks to somewhere in /home
 
147
 
 
148
os.rename(os.path.join(ivle.conf.jail_system, 'etc/passwd'),
 
149
          os.path.join(ivle.conf.jail_system, 'home/.passwd')
 
150
          )
 
151
os.symlink('../home/.passwd', os.path.join(ivle.conf.jail_system, 'etc/passwd'))
 
152
 
 
153
os.makedirs(os.path.join(ivle.conf.jail_system, "etc/ivle"))
 
154
os.symlink('../home/.ivle.conf',
 
155
           os.path.join(ivle.conf.jail_system, "etc/ivle/ivle.conf"))