This commit is contained in:
Ian Gulliver
2016-04-29 19:16:48 +00:00
parent 70dd367261
commit 71fd9f8dba

View File

@@ -43,7 +43,7 @@ def main():
if FLAGS.sudo:
with open(os.path.join(FLAGS.chroot_path, 'etc', 'sudoers.d', FLAGS.username), 'w') as fh:
fh.write('%s\tALL=(ALL) NOPASSWD: ALL\n')
fh.write('%s\tALL=(ALL) NOPASSWD: ALL\n' % FLAGS.username)
if FLAGS.authorized_keys_file:
dest_dir = os.path.join(FLAGS.chroot_path, 'home', FLAGS.username, '.ssh')