ばーろぐわにる

SIerからWEB系?インフラエンジニアにジョブチェンジした見習いの備忘録。投稿内容は私個人の意見であり、所属企業・部門見解を代表するものではありません。

Ansibleインストール、テスト

環境

ubuntu@ip-172-31-0-101:~$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=16.04
DISTRIB_CODENAME=xenial
DISTRIB_DESCRIPTION="Ubuntu 16.04.3 LTS"

ubuntu@ip-172-31-0-101:~$ uname -a
Linux ip-172-31-0-101 4.4.0-1054-aws #63-Ubuntu SMP Wed Mar 28 19:42:42 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux

インストール

公式ドキュメントを参考に最新版をインストール

$ sudo apt-get update
$ sudo apt-get install software-properties-common
$ sudo apt-add-repository ppa:ansible/ansible
$ sudo apt-get update
$ sudo apt-get install ansible

software-properties-commonディストリビューションや独自ソフトウェアベンダのリポジトリを簡単に管理できるもの。ここではansibleのppaを抽象的に追加している。

https://allabout.co.jp/gm/gc/438675/

https://askubuntu.com/questions/1000118/what-is-software-properties-common?utm_medium=organic&utm_source=google_rich_qa&utm_campaign=google_rich_qa

ubuntu@ip-172-31-0-101:~$ ansible --version
ansible 2.5.2
config file = /etc/ansible/ansible.cfg
configured module search path = [u'/home/ubuntu/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']
ansible python module location = /usr/lib/python2.7/dist-packages/ansible
executable location = /usr/bin/ansible
python version = 2.7.12 (default, Dec 4 2017, 14:50:18) [GCC 5.4.0 20160609]

とりあえずインストールまで。明日から本気出す。