Vagrant: `vagrant ssh` should start box, `vagrant up`

Created on 5 Sep 2012  路  5Comments  路  Source: hashicorp/vagrant

Hello,

I was just thinking vagrant ssh could start a box, vagrant up, when it is not started already.

Instead of showing the message
VM must be running to open SSH connection. Runvagrant up` to start the virtual machine.

Vagrant would just start the box and notice it in the log.

All 5 comments

+1
thought about exactly the same 2 days ago

:-1:

This wouldn't strike me as an expected behaviour...

I'm going to veto this change.

It has been suggested a couple times. The main issue is that vagrant up can actually become quite expensive (in terms of time). Therefore I'd like to avoid magically bringing up a VM. I'd like to keep the comments distinct. The same idea for vagrant provision (some have suggested that should bring it up as well).

I can see that if you're trying to ssh you might expect the VM to be up, but it really isn't that much more time to run vagrant up and this keeps the separation much cleaner.

Oh, also, you can add this functionality yourself with a plugin in the next version of Vagrant by instrumenting the ssh action. :)

vagrant up; vagrant ssh

Should solve this for you. :)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

StefanScherer picture StefanScherer  路  3Comments

mpontillo picture mpontillo  路  3Comments

OtezVikentiy picture OtezVikentiy  路  3Comments

barkingfoodog picture barkingfoodog  路  3Comments

janw-me picture janw-me  路  3Comments