Created
August 12, 2014 20:37
-
-
Save januswel/c0e82fd8582710969c88 to your computer and use it in GitHub Desktop.
ssh config を汚さずに Ansible で Vagrant ホストを扱う ref: http://qiita.com/janus_wel/items/faac04f2ec2cdb50d074
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
[defaults] | |
hostfile = .vagrant/provisioners/ansible/inventory/vagrant_ansible_inventory | |
remote_user = vagrant | |
private_key_file = ~/.vagrant.d/insecure_private_key | |
host_key_checking = False |
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
--- # generate ansible inventory file with Vagrant | |
- hosts: default | |
tasks: | |
- name: ping | |
action: ping |
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
config.vm.provision "ansible" do |ansible| | |
ansible.host_key_checking = false | |
ansible.playbook = "generate-inventory.yml" | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment