require 'vagrant-aws'
Vagrant.configure('2') do |config|
config.vm.box = "aws-box"
config.vm.box_url = "https://github.com/mitchellh/vagrant-aws/raw/master/dummy.box"
config.vm.define "jupiter" do |jupiter|
jupiter.vm.provision "shell", path: "install_ansible.sh"
jupiter.vm.provider 'aws' do |aws, override|
aws.access_key_id = ENV['AWS_ACCESS_KEY_ID']
aws.secret_access_key = ENV['AWS_SECRET_ACCESS_KEY']
aws.keypair_name = 'vagrant'
aws.region = 'us-west-2'
aws.ami = 'ami-20be7540'
aws.security_groups = ['default']
override.ssh.username = 'ansible'
override.ssh.private_key_path = '~/ec2/keys/vagrant.pem'
aws.tags = {
'Name' => "ansible"
}
end
end
This blog is no longer being maintained - live version now at https://devopsrunbook.wordpress.com/
Sunday, 27 August 2017
Vagrant and AWS
An example Vagrantfile
Subscribe to:
Post Comments (Atom)
Fabulous post admin, it was too good and helpful. Waiting for more updates.
ReplyDeleteDevOps Training in Chennai
DevOps course in Chennai
AWS Training in Chennai
AWS Training in Velachery
Cloud Computing Courses in Chennai
RPA course in Chennai
DevOps Training in OMR
DevOps Training in Chennai