digital ocean - Setting up a vagrant with a digitalocean image -
i dont know if should posted here or on stack community please let me know if wrong posting here.
how local (i.e. on laptop) vm identical droplet (ubuntu 14.04 - lamp etc) running?
does provide provisioner vagrant can replicate setup of droplet?
it's handy being able develop on machine, instead of on droplet in cloud.
it should possible, never tried myself (as switch ec2) saw there digital ocean plugin, can refer following page https://www.digitalocean.com/community/tutorials/how-to-use-digitalocean-as-your-provider-in-vagrant-on-an-ubuntu-12-10-vps
basically need following:
install plugin , download base box
vagrant plugin install vagrant-digitalocean vagrant box add digital_ocean https://github.com/smdahlen/vagrant-digitalocean/raw/master/box/digital_ocean.box
create ssh keys needed authentication digitalocean. run following command generate ssh key pair:
ssh-keygen -t rsa
you can accept defaults pressing enter. place ssh private , public keys path specify below in vagrantfile configuration.
create
vagrantfile
following minimal configurationconfig.vm.box = "digital_ocean" config.ssh.private_key_path = "~/.ssh/id_rsa" config.vm.provider :digital_ocean |provider| provider.client_id = "your client id" provider.api_key = "your api key" provider.image = "ubuntu 12.10 x64" provider.region = "new york 2" end
run vagrant
vagrant --provider=digital_ocean
you can refer above link additional parameters , fix issues face
Comments
Post a Comment