diff --git a/centos-atomic/docker-tcp-ansible/Vagrantfile b/centos-atomic/docker-tcp-ansible/Vagrantfile index 9de1b53..4eb77bd 100644 --- a/centos-atomic/docker-tcp-ansible/Vagrantfile +++ b/centos-atomic/docker-tcp-ansible/Vagrantfile @@ -77,7 +77,7 @@ Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| # Provision the VM with Ansible config.vm.provision 'ansible' do |ansible| - ansible.playbook = 'provision.yml' + ansible.playbook = 'ansible.yml' end # config.vm.provision end # machines.each end # Vagrant.configure diff --git a/centos-atomic/docker-tcp-ansible/provision.yml b/centos-atomic/docker-tcp-ansible/ansible.yml similarity index 100% rename from centos-atomic/docker-tcp-ansible/provision.yml rename to centos-atomic/docker-tcp-ansible/ansible.yml diff --git a/consul/consul-ansible/README.md b/consul/consul-ansible/README.md index 13e791c..3d5f86f 100644 --- a/consul/consul-ansible/README.md +++ b/consul/consul-ansible/README.md @@ -6,6 +6,8 @@ These files were created to allow users to use Vagrant ([http://www.vagrantup.co * **ansible.cfg**: This Ansible configuration file tells Ansible which inventory file to use (a file named `hosts` in the current directory), which SSH private key to use (the default Vagrant insecure key), and which remote user to use (the default user of `vagrant` that should be common to all Vagrant boxes). No edits to this file should be necessary. +* **ansible.yml**: This is the Ansible playbook that will configure the Vagrant VMs to become members of a Consul cluster. No edits to this file should be necessary. + * **config.json.j2**: This Jinja2 template is automatically filled in with appropriate values by Ansible when the Ansible playbook is applied against the Vagrant VMs. No edits to this file should be necessary. * **consul.conf**: This Upstart script configures Consul to run as a background daemon (service) on the Ubuntu-based VMs created by Vagrant. This file is installed by Ansible when the Ansible playbook is applied against the Vagrant VMs. No edits to this file should be necessary. @@ -14,8 +16,6 @@ These files were created to allow users to use Vagrant ([http://www.vagrantup.co * **machines.yml**: This YAML file contains a list of VM definitions. It is referenced by `Vagrantfile` when Vagrant instantiates the VMs. Generally, the only change needed to this file is to specify the correct Vagrant box you will be used (see "Instructions" below). If necessary, you may need to edit the IP addresses supplied in this file to avoid IP addressing conflicts with other networks. -* **provision.yml**: This is the Ansible playbook that will configure the Vagrant VMs to become members of a Consul cluster. No edits to this file should be necessary. - * **README.md**: This file you're currently reading. * **Vagrantfile**: This file is used by Vagrant to spin up the virtual machines. This file is fairly extensively commented to help explain what's happening. You should be able to use this file unchanged; all the VM configuration options are stored outside this file. @@ -32,7 +32,7 @@ These instructions assume you've already installed VMware Fusion, Vagrant, the V 4. Once you have edited `machines.yml`, use `vagrant up` to bring up the 3 systems that will serve as your Consul cluster. -5. Once Vagrant has finished bringing up the VMs, run `ansible-playbook provision.yml`. Ansible will use the configuration file in the current directory to pull inventory from the file named `hosts` (it was automatically generated when you ran `vagrant up`). This will provision and configure Consul on each of the Vagrant VMs. +5. Once Vagrant has finished bringing up the VMs, run `ansible-playbook ansible.yml`. Ansible will use the configuration file in the current directory to pull inventory from the file named `hosts` (it was automatically generated when you ran `vagrant up`). This will provision and configure Consul on each of the Vagrant VMs. **NOTE**: Due to the way the Ansible provisioner in Vagrant works, it's currently not possible to provision the VMs with Ansible from within the `Vagrantfile`. As a result, step #5 (running `ansible-playbook` manually) is needed. diff --git a/lxc-lxd/lxd-ansible/README.md b/lxc-lxd/lxd-ansible/README.md index 27b3ea9..debcd52 100644 --- a/lxc-lxd/lxd-ansible/README.md +++ b/lxc-lxd/lxd-ansible/README.md @@ -6,12 +6,12 @@ These files were created to allow users to use Vagrant ([http://www.vagrantup.co * **ansible.cfg**: This Ansible configuration file instructs Ansible to use an inventory file named `hosts` in the current directory, and to use the default vagrant user (`vagrant`) and default insecure Vagrant SSH private key. +* **ansible.yml**: This YAML file is an Ansible playbook that configures the VMs created by Vagrant when they are first provisioned. Ansible is called automatically by Vagrant; you do not need to invoke Ansible separately. No changes are needed to this file. + * **hosts**: This file is created automatically when you run `vagrant status` or `vagrant up` (anytime Vagrant processes `Vagrantfile`). This file relies on the presence of a "ip_addr" value in `machines.yml`. Do not edit this file directly---instead edit `machines.yml` to change the values that will be automatically written into this file. * **machines.yml**: This YAML file contains a list of VM definitions and associated configuration data. It is referenced by `Vagrantfile` when Vagrant instantiates the VMs. Only minimal changes may be needed to this file; see the "Instructions" section below. -* **provision.yml**: This YAML file is an Ansible playbook that configures the VMs created by Vagrant when they are first provisioned. Ansible is called automatically by Vagrant; you do not need to invoke Ansible separately. No changes are needed to this file. - * **README.md**: The file you're currently reading. * **Vagrantfile**: This file is used by Vagrant to spin up the virtual machines. This file is fairly extensively commented to help explain what's happening. You should be able to use this file unchanged; all the VM configuration options are stored outside this file. diff --git a/lxc-lxd/lxd-ansible/Vagrantfile b/lxc-lxd/lxd-ansible/Vagrantfile index 0ba2db7..eeaa3ec 100644 --- a/lxc-lxd/lxd-ansible/Vagrantfile +++ b/lxc-lxd/lxd-ansible/Vagrantfile @@ -57,7 +57,7 @@ Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| # Provision the VM with Ansible config.vm.provision 'ansible' do |ansible| - ansible.playbook = 'provision.yml' + ansible.playbook = 'ansible.yml' end # config.vm.provision end # machines.each end # Vagrant.configure diff --git a/lxc-lxd/lxd-ansible/provision.yml b/lxc-lxd/lxd-ansible/ansible.yml similarity index 100% rename from lxc-lxd/lxd-ansible/provision.yml rename to lxc-lxd/lxd-ansible/ansible.yml diff --git a/packer/aws-ami-ansible/README.md b/packer/aws-ami-ansible/README.md index 5caa1c8..4f0a92f 100644 --- a/packer/aws-ami-ansible/README.md +++ b/packer/aws-ami-ansible/README.md @@ -8,7 +8,7 @@ These files show an example of how to use Packer ([https://www.packer.io/](https ## Contents -* **provision.yml**: This Ansible playbook applies the "docker-ce-edge" role to the AMI being created by Packer, and is called by `template.json`. +* **ansible.yml**: This Ansible playbook applies the "docker-ce-edge" role to the AMI being created by Packer, and is called by `template.json`. * **README.md**: This file you're currently reading. diff --git a/packer/aws-ami-ansible/provision.yml b/packer/aws-ami-ansible/ansible.yml similarity index 100% rename from packer/aws-ami-ansible/provision.yml rename to packer/aws-ami-ansible/ansible.yml diff --git a/packer/aws-ami-ansible/template.json b/packer/aws-ami-ansible/template.json index 918ad76..c370cfe 100644 --- a/packer/aws-ami-ansible/template.json +++ b/packer/aws-ami-ansible/template.json @@ -33,7 +33,7 @@ "provisioners": [ { "type": "ansible", - "playbook_file": "provision.yml" + "playbook_file": "ansible.yml" } ] } diff --git a/photon/photon-ansible/Vagrantfile b/photon/photon-ansible/Vagrantfile index eb52e4a..f6e9dd7 100644 --- a/photon/photon-ansible/Vagrantfile +++ b/photon/photon-ansible/Vagrantfile @@ -64,7 +64,7 @@ Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| # Provision the VM with Ansible config.vm.provision 'ansible' do |ansible| - ansible.playbook = 'provision.yml' + ansible.playbook = 'ansible.yml' end # config.vm.provision end # machines.each end # Vagrant.configure diff --git a/photon/photon-ansible/provision.yml b/photon/photon-ansible/ansible.yml similarity index 100% rename from photon/photon-ansible/provision.yml rename to photon/photon-ansible/ansible.yml