ども、cloudpack の 全部初心者のかっぱ (@inokara) です。 はじめに 沢山のホストに同じ設定をぶち込みたい時に Ansible が気持ちよかったのでメモ。 インベントリファイルの準備 以下のようなインベントファイルを test-hosts という名前で保存しておく。 [foo-bar] xxx.xxx.xxx.xxx ansible_connection=ssh ansible_ssh_user=ssh-user ansible_ssh_private_key_file=~/.ssh/key.pem ansible 編 ohai 的なの python では fact が ohai 的な動きをして対象ホストの情報を JSON で返却する。 ansible -i test-hosts test-host -m setup Amazon Linux の場合には以下のように J
