fails if no ssh keys exist

Bug #366268 reported by Kees Cook on 2009-04-24
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
vm-builder (Ubuntu)
Undecided
Unassigned

Bug Description

...
2009-04-24 11:27:28,147 DEBUG loop deleted : /dev/loop0
2009-04-24 11:27:28,148 DEBUG ['rmdir', '/home/kees/vm-images/clean-jaunty-amd64']
2009-04-24 11:27:28,155 DEBUG ['rm', '-rf', '/tmp/vmbuilderQUxrf5']
Traceback (most recent call last):
  File "/usr/bin/vmbuilder", line 29, in <module>
    VMBuilder.run()
  File "/usr/lib/python2.6/dist-packages/VMBuilder/__init__.py", line 66, in run
    frontend.run()
  File "/usr/lib/python2.6/dist-packages/VMBuilder/plugins/cli/__init__.py", line 67, in run
    vm.create()
  File "/usr/lib/python2.6/dist-packages/VMBuilder/vm.py", line 457, in create
    self.install()
  File "/usr/lib/python2.6/dist-packages/VMBuilder/vm.py", line 396, in install
    self.distro.install(self.installdir)
  File "/usr/lib/python2.6/dist-packages/VMBuilder/plugins/ubuntu/distro.py", line 131, in install
    self.suite.install(destdir)
  File "/usr/lib/python2.6/dist-packages/VMBuilder/plugins/ubuntu/dapper.py", line 82, in install
    self.install_authorized_keys()
  File "/usr/lib/python2.6/dist-packages/VMBuilder/plugins/ubuntu/dapper.py", line 111, in install_authorized_keys
    shutil.copy(self.vm.ssh_key, '%s/root/.ssh/authorized_keys' % self.destdir)
  File "/usr/lib/python2.6/shutil.py", line 88, in copy
    copyfile(src, dst)
  File "/usr/lib/python2.6/shutil.py", line 52, in copyfile
    fsrc = open(src, 'rb')
IOError: [Errno 2] No such file or directory: '/home/kees/.ssh/id_rsa.pub'

Kees Cook (kees) wrote :

This bug is a problem for when the user running vm-builder lacks ssh keys to start with. (i.e. a warning should be added rather than building the entire VM and then exploding.)

Chuck Short (zulcss) wrote :

Kees,

Is this still a problem for you?

Regards
chuck

Changed in vm-builder (Ubuntu):
status: New → Incomplete
Chuck Short (zulcss) wrote :

I do believe this is fixed now.

Regards
chuck

Changed in vm-builder (Ubuntu):
status: Incomplete → Fix Committed
Loïc Minier (lool) wrote :

Chuck, was this in the last uploaded release?

JC Hulce (soaringsky) wrote :

This bug has been marked as Fix Committed for over a year. If the fix has made it into Ubuntu, please mark this bug as Fix Released. If the fix has been released upstream, but not Ubuntu, create a new bug asking for the new version and tag it with upgrade-software-version. If this bug stays inactive for a long period, it may be expired.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers