Home:ALL Converter>ubuntu-vm-builder fails on /etc/sudoers - any workaround?

ubuntu-vm-builder fails on /etc/sudoers - any workaround?

Ask Time:2016-10-14T07:38:21         Author:user7016441

Json Formatter

I'm on 16.04 and trying to install a 16.04 guest using this:

ubuntu-vm-builder kvm xenial -v --mem 1024  --hostname tester 
   --addpkg openssh-server --mirror http://office:3142/ubuntu

Pretty normal right?

It dies at:

Setting up sudo (1.8.16-0ubuntu1.2) ...

Configuration file '/etc/sudoers'
 ==> Modified (by you or by a script) since installation.
 ==> Package distributor has shipped an updated version.
   What would you like to do about it ?  Your options are:
    Y or I  : install the package maintainer's version
    N or O  : keep your currently-installed version
      D     : show the differences between the versions
      Z     : start a shell to examine the situation
 The default action is to keep your current version.
*** sudoers (Y/I/N/O/D/Z) [default=N] ? dpkg: error processing package sudo (--configure):
 end of file on stdin at conffile prompt
    .... more message....
Errors were encountered while processing:
 sudo
Extracting templates from packages: 100%
W: --force-yes is deprecated, use one of the options starting with --allow instead.
E: Sub-process /usr/bin/dpkg returned an error code (1)

Any ideas on this?

Is ubuntu-vm-builder even the right tool to use now, or is there a modern replacement? I'm a bit lost in the variety of VM creation tools out there.

I did search on this and the only information I found a suggestion to edit /usr/lib/python2.7/dist-packages/VMBuilder/plugins/ubuntu/dapper.py. I could do this but... is that really the standard way to handle VM creation on Ubuntu these days?

Edit: I did edit that file and replaced dist-update with upgrade, as suggested, and then it worked. Pretty weird that an Ubuntu LTS package would ship in a way that fails every time (no one tested it even once before release), unless I'm really doing something wrong with this.

Thank you

Author:user7016441,eproduced under the CC 4.0 BY-SA copyright license with a link to the original source and this disclaimer.
Link to original article:https://stackoverflow.com/questions/40032727/ubuntu-vm-builder-fails-on-etc-sudoers-any-workaround
yy