From c20c6d4eb4fe28e264ed08a17bf32f36df1798d9 Mon Sep 17 00:00:00 2001 From: Erika Heidi Date: Mon, 2 Feb 2015 13:30:17 +0100 Subject: [PATCH] [Vagrant guide] Updating private key location Since Vagrant 1.7.0, released in December 2014, the private key file is autogenerated and has a new location - check the changelog for more info: [version 1.7.0 changelog](https://github.com/mitchellh/vagrant/blob/master/CHANGELOG.md#170-december-9-2014) --- docsite/rst/guide_vagrant.rst | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/docsite/rst/guide_vagrant.rst b/docsite/rst/guide_vagrant.rst index 8dc8d10b44..f61fd84feb 100644 --- a/docsite/rst/guide_vagrant.rst +++ b/docsite/rst/guide_vagrant.rst @@ -107,14 +107,16 @@ inventory file may look something like this: If you want to run Ansible manually, you will want to make sure to pass ``ansible`` or ``ansible-playbook`` commands the correct arguments for the -username (usually ``vagrant``) and the SSH key (usually -``~/.vagrant.d/insecure_private_key``), and the autogenerated inventory file. +username (usually ``vagrant``) and the SSH key (since Vagrant 1.7.0, this will be something like +``.vagrant/machines/[machine name]/[provider]/private_key``), and the autogenerated inventory file. Here is an example: .. code-block:: bash - $ ansible-playbook -i .vagrant/provisioners/ansible/inventory/vagrant_ansible_inventory --private-key=~/.vagrant.d/insecure_private_key -u vagrant playbook.yml + $ ansible-playbook -i .vagrant/provisioners/ansible/inventory/vagrant_ansible_inventory --private-key=.vagrant/machines/default/virtualbox/private_key -u vagrant playbook.yml + +Note: Vagrant versions prior to 1.7.0 will use the private key located at ``~/.vagrant.d/insecure_private_key.`` .. seealso::