Skip to content

Commit

Permalink
moves development:vars definition into vagrantfile. documents creatio…
Browse files Browse the repository at this point in the history
…n of symlink.
  • Loading branch information
discopatrick committed Feb 11, 2017
1 parent 07ad4d3 commit 1c53730
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 3 deletions.
11 changes: 11 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,17 @@ An ansible project that solves and documents some of the issues I've faced while

Keeping these examples in a simple, isolated project lets me refer to known working examples, in case I ever have issues while working in more complex projects.

## To run the playbooks yourself

Playbooks are set to run against local (development) machines, remote (staging) machines, or both. Check the playbook `hosts` setting to see.

To run the playbooks against remote machines, first create two $5 machines running Ubuntu 14.04.5 x64, and add their IPs to the hosts directory (see the example there).

If you're running playbooks against local machines:
- `vagrant up` to create the two local dev machines. Wait for this to complete.
- `cd hosts`
- `ln -s ../.vagrant/provisioners/ansible/inventory/vagrant_ansible_inventory _development` to create a symlink from the hosts directory to Vagrant's automatically generated inventory file.

## Ansible version

New versions of Ansible are released regularly. The playbooks in this project are always tested against a specific version, which is specified in requirements.txt (e.g. `ansible==2.2.1.0`).
Expand Down
5 changes: 4 additions & 1 deletion Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,10 @@ Vagrant.configure(2) do |config|
ansible.groups = {
"development" => ['alpha', 'beta'],
"primary" => ['alpha'],
"secondary" => ['beta']
"secondary" => ['beta'],
"development:vars" => {
"ansible_ssh_extra_args" => "'-o StrictHostKeyChecking=no -o ForwardAgent=yes'"
}
}

end
Expand Down
2 changes: 0 additions & 2 deletions hosts/_development_vars

This file was deleted.

0 comments on commit 1c53730

Please sign in to comment.