• LOGIN
  • No products in the cart.

DevOps on AWS – Vagrant File for Ansible Exercise

# -*- mode: ruby -*-
# vi: set ft=ruby :
VAGRANTFILE_API_VERSION = “2”
ENV[‘VAGRANT_DEFAULT_PROVIDER’] = ‘virtualbox’

Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
config.vm.define “ansible1” do |ansible1|
ansible1.vm.hostname = “ansible1.rnstech.com”
ansible1.vm.box = “bento/centos-7.2”
ansible1.vm.box_url = “bento/centos-7.2”

config.vm.network “public_network”, bridge: “Broadcom 802.11n Network Adapter”
 # manual ip
  config.vm.provision “shell”,
    run: “always”,
    inline: “ifconfig enp0s8 192.168.10.20 netmask 255.255.255.0 up”

  # manual ipv6
  config.vm.provision “shell”,
    run: “always”,
    inline: “ifconfig enp0s8 inet6 add fc00::18/7”
end

config.vm.define “ansible2” do |ansible2|

ansible2.vm.hostname = “ansible2.rnstech.com”
ansible2.vm.box = “bento/centos-7.2”
ansible2.vm.box_url = “bento/centos-7.2”

ansible2.vm.network “public_network”, bridge: “Broadcom 802.11n Network Adapter”
 # manual ip
  ansible2.vm.provision “shell”,
    run: “always”,
    inline: “ifconfig enp0s8 192.168.10.21 netmask 255.255.255.0 up”

  # manual ipv6
  ansible2.vm.provision “shell”,
    run: “always”,
    inline: “ifconfig enp0s8 inet6 add fc00::17/7”
end
end
February 22, 2021

Contact Address

Rise ‘n’ Shine Technologies:
Third Floor, Plot No1(Part), near KPHB Metro Station, KPHB Bagyanagar Colony, Kukatpally Main road, Balanagar Mandal, Rangareddy Dist-500072

Landmarks : Above VIOLET & PURPLE, near PJR statue, kphb metro station

  8686 98 8042
rnstech.fmw@gmail.com

Location

All rights reserved.
error: Alert: Content is protected !!
X