Merge lp:~rbalint/livecd-rootfs/vagrant-interactive-xenial into lp:~ubuntu-core-dev/livecd-rootfs/xenial-proposed

Proposed by Balint Reczey
Status: Merged
Merged at revision: 1452
Proposed branch: lp:~rbalint/livecd-rootfs/vagrant-interactive-xenial
Merge into: lp:~ubuntu-core-dev/livecd-rootfs/xenial-proposed
Diff against target: 29 lines (+10/-1)
2 files modified
debian/changelog (+7/-0)
live-build/ubuntu-cpc/hooks/042-vagrant.binary (+3/-1)
To merge this branch: bzr merge lp:~rbalint/livecd-rootfs/vagrant-interactive-xenial
Reviewer Review Type Date Requested Status
Chris Glass (community) Approve
Review via email: mp+335508@code.launchpad.net

Description of the change

Fix running vagrant image build interactively.

To post a comment you must log in.
Revision history for this message
Balint Reczey (rbalint) wrote :

Without the fix the build asks for password for the new user when running lb in interactive shell and this blocks the build.

1452. By Balint Reczey

Don't ask for password and GECOS while creating vagrant user

1453. By Balint Reczey

Update changelog

Revision history for this message
Chris Glass (tribaal) wrote :

Thanks for adding the comment!
+1

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'debian/changelog'
--- debian/changelog 2017-12-18 09:11:26 +0000
+++ debian/changelog 2017-12-21 08:51:27 +0000
@@ -1,3 +1,10 @@
1livecd-rootfs (2.408.27) xenial; urgency=medium
2
3 * Don't ask for password and GECOS while creating vagrant user
4 (LP: #1569237)
5
6 -- Balint Reczey <rbalint@ubuntu.com> Thu, 21 Dec 2017 09:20:32 +0100
7
1livecd-rootfs (2.408.26) xenial; urgency=medium8livecd-rootfs (2.408.26) xenial; urgency=medium
29
3 * Added a "vagrant" user to the vagrant image in addition to the "ubuntu"10 * Added a "vagrant" user to the vagrant image in addition to the "ubuntu"
411
=== modified file 'live-build/ubuntu-cpc/hooks/042-vagrant.binary'
--- live-build/ubuntu-cpc/hooks/042-vagrant.binary 2017-12-07 13:09:43 +0000
+++ live-build/ubuntu-cpc/hooks/042-vagrant.binary 2017-12-21 08:51:27 +0000
@@ -63,7 +63,9 @@
63# Vagrant users expect a "vagrant" user with a "vagrant" username.63# Vagrant users expect a "vagrant" user with a "vagrant" username.
64# See https://www.vagrantup.com/docs/boxes/base.html64# See https://www.vagrantup.com/docs/boxes/base.html
65# Note: We decided NOT to allow root login with a default password.65# Note: We decided NOT to allow root login with a default password.
66chroot ${mount_d} adduser vagrant66# --disabled-password and --gecos need to be passed to avoid adduser
67# asking questions when running in an interactive shell
68chroot ${mount_d} adduser vagrant --disabled-password --gecos ""
67echo "vagrant:vagrant" | chroot ${mount_d} chpasswd69echo "vagrant:vagrant" | chroot ${mount_d} chpasswd
6870
69# The vagrant user should have passwordless sudo.71# The vagrant user should have passwordless sudo.

Subscribers

People subscribed via source and target branches