Ansible 簡介
認識 Ansible
大綱
簡介
安裝部署工具、設定管理工具等
同類型工具:Chef、Puppet、SaltStack
不需要 Agent、透過 ssh
Linux 有 python 即可 ( ssh port )
Win 啟用 winrm 即可 ( 5986 port )
資料夾結構簡單易懂、官方文件豐富易懂、模組多支援設備多、易撰寫


安裝
pip install ansible
- pip3 install ansible
yum install ansible
apt-get install ansible
apk add ansible

常用模組
常用模組 - ping

常用模組 - shell / command


常用模組 - file

常用模組 - yum

常用模組 - systemd / service


常用模組 - template / copy



常用模組 - debug / register




資料夾結構



結語
- 選擇適合的
- ansible ad-hoc
ansible gitlab -m pingansible gitlab -m shell -a 'rm -rf /'
- playbook
- role
- collection
- shell script
- python script
- others
- ansible ad-hoc
