I have a playbook that will update the local source code for my web project 
and then it will deploy it to remote servers. 
Everything works when i run it locally on OS X, but when i try to run from 
the deployment server (aws linux)  I get no matching host errors

I'm a little confused at why it would work locally but not remotely.  This 
is the  message i get:


PLAY [Get latest Code] 
*********************************************************

skipping: no hosts matched

Do i need to add localhost to the inventory first, and if so how to i keep 
it from being included in the 2nd step? 
The biggest puzzle is why it works on the mac but not on linux.  Ansible 
was installed using pip on both so not sure what could be different on them

Below is the command and code.

Thanks,
Daniel


ansible playbook command:

ansible-playbook -i inventory/dev/ -l ~tag_role_web full-deploy.yml 


ansible playbook


- name: Get latest Code

  gather_facts: no

  hosts: localhost

  vars:

     next_color_name: "{{ lookup('file', './src/nextArchive') }}"

     update_archive: "{{ next_color_name }}-web"

  roles:

  - role: update-code



- name: Deploy web code

  hosts: all

  vars:

     latest_archive: "{{ lookup('file', './src/nextArchive') }}"

  roles:

  - role: deploy-web



-- 
You received this message because you are subscribed to the Google Groups 
"Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ansible-project/6273aaad-256e-49e7-9b33-a1a476ab31db%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to