-
Notifications
You must be signed in to change notification settings - Fork 1
Setup development with vagrant
Geun edited this page Jun 19, 2014
·
4 revisions
- create vagrant stage at
config/deploy/vagrant.rb
- normally, vagrant has private key for connecting with SSL, so you should set ssh_options and enable
forward_agent
options
set :ssh_options, {
keys: %w(~/.vagrant.d/insecure_private_key),
forward_agent: true,
auth_methods: %w(publickey)
}
command : vagrant ssh server_name
if you define master server in 'Vagrantfile
config.vm.define "master" do |master|
master.vm.box = "saucy64"
master.vm.box_url = "http://cloud-images.ubuntu.com/vagrant/precise/current/precise-server-cloudimg-amd64-vagrant-disk1.box"
master.vm.network :private_network, ip: "192.168.33.101"
master.vm.network :forwarded_port, guest: 80, host: 4000
end
and connect to master like this
vagrant ssh master
run capistrano3
bundle exec cap vagrant utils:uptime