Skip to content

Instantly share code, notes, and snippets.

@mark-obrien
Created August 31, 2015 18:59
Show Gist options
  • Select an option

  • Save mark-obrien/cbca96b28d0a2921b5ff to your computer and use it in GitHub Desktop.

Select an option

Save mark-obrien/cbca96b28d0a2921b5ff to your computer and use it in GitHub Desktop.
Vagrant SSH Auth Error Fix
dir = File.dirname(File.expand_path(__FILE__))
require 'yaml'
require "#{dir}/puphpet/ruby/deep_merge.rb"
configValues = YAML.load_file("#{dir}/puphpet/config.yaml")
if File.file?("#{dir}/puphpet/config-custom.yaml")
custom = YAML.load_file("#{dir}/puphpet/config-custom.yaml")
configValues.deep_merge!(custom)
end
data = configValues['vagrantfile']
Vagrant.configure("2") do |config|
config.ssh.insert_key = false
end
Vagrant.require_version '>= 1.6.0'
eval File.read("#{dir}/puphpet/vagrant/Vagrantfile-#{data['target']}")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment