Deployment of AppServer Using Vagrant and Ansible
This repository contains scripts of Vagrant and Ansible to automatically deploy an Application Server with Load Balancer and Database backend.
- Vitualbox
- Vagrant
- Clone this repository
$ git clone https://github.com/cshuo/vagrant-ansible-appserver.git
- Modify configurations of VMs according to your physical environment, e.g, size of memory and number of CPU.
- Bootup the VMs using Vagrant commands
$ cd vagrant-ansible-appserver
$ vagrant up
Waiting for a while, 3 Vms will be started.
- Deploy Application Server using Ansible, ssh into the control vm node, and run ansible playbooks.
$ vagrant ssh appserver
$ cd /vagrant/apt
$ ansible-playbook -i hosts playbook.yml