Created
December 4, 2013 13:57
-
-
Save masahide/7787778 to your computer and use it in GitHub Desktop.
ansible-playbook ワンライナー ref: http://qiita.com/yamasaki-masahide/items/fa96225815869daa9e53
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ diff -u <(ssh host1 cat /etc/hosts) <(ssh host2 cat /etc/hsots) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ ansible-playbook -i <(curl -s https://raw.github.com/masahide/playbook-sample/master/localhost) <(curl -s https://raw.github.com/masahide/playbook-sample/master/sample.yml) -e dir=`pwd` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ ansible-playbook -i <(curl -s https://raw.github.com/masahide/playbook-sample/master/localhost) <(curl -s https://raw.github.com/masahide/playbook-sample/master/sample.yml) -e dir=`pwd` | |
PLAY [localhost] ************************************************************** | |
TASK: [create directories for ansible files.] ********************************* | |
changed: [localhost] => (item=/home/masahide/work/playbook/group_vars) | |
changed: [localhost] => (item=/home/masahide/work/playbook/host_vars) | |
changed: [localhost] => (item=/home/masahide/work/playbook/roles/common/tasks) | |
changed: [localhost] => (item=/home/masahide/work/playbook/roles/common/defaults) | |
changed: [localhost] => (item=/home/masahide/work/playbook/roles/common/handlers) | |
changed: [localhost] => (item=/home/masahide/work/playbook/roles/common/templates) | |
changed: [localhost] => (item=/home/masahide/work/playbook/roles/common/files) | |
changed: [localhost] => (item=/home/masahide/work/playbook/roles/common/vars) | |
PLAY RECAP ******************************************************************** | |
localhost : ok=1 changed=1 unreachable=0 failed=0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment