앤서블_명령어 썸네일형 리스트형 Ansible lineinfile 모듈 Ansible lineinfile 모듈lineinfile 모듈- 호스트 파일 편집(/etc/ansible/hosts)$ ansible dbs -m lineinfile -b -K -a "dest=/etc/hosts line='10.31.3.72 galera01' state=present"BECOME password:db1 | CHANGED => { "backup": "", "changed": true, "msg": "line added"}db3 | CHANGED => { "backup": "", "changed": true, "msg": "line added"}db2 | CHANGED => { "backup": "", "changed": true, "msg".. 더보기 Ansible shell, command, yum, user 모듈 Ansible shell, command, yum, user 모듈Ansible에서 모듈 사용법shell 모듈$ ansible db1 -m shell -a "free -h"db1 | CHANGED | rc=0 >> total used free shared buff/cache availableMem: 3.8G 162M 2.7G 540K 997M 3.4GSwap: 0B 0B 0Bcommand 모듈$ ansible db1 -m command -a "cat /etc/passwd"db1 | CHANGED | rc=0 >>r.. 더보기 이전 1 다음