Copy the public key into place instead of moving it

This gets around reprovisioning issues
This commit is contained in:
Jose Diaz-Gonzalez
2015-03-19 20:07:32 -04:00
parent 6f52853049
commit aee8ada6d0

2
Vagrantfile vendored
View File

@@ -53,6 +53,6 @@ Vagrant::configure("2") do |config|
if Pathname.new(PUBLIC_KEY_PATH).exist?
config.vm.provision :file, source: PUBLIC_KEY_PATH, destination: '/tmp/id_rsa.pub'
config.vm.provision :shell, :inline => "rm /root/.ssh/authorized_keys && mv /tmp/id_rsa.pub /root/.ssh/authorized_keys"
config.vm.provision :shell, :inline => "rm -f /root/.ssh/authorized_keys && cp /tmp/id_rsa.pub /root/.ssh/authorized_keys"
end
end