ansibleplaybook1 Ansible Playbooks Inventory 에서 정의된 호스트에서 무엇을 해야할지를 정의한 것. 자동화 절차를 기술한 코드 파일 코드 Set을 의미함. YAML 형식으로 기록 playbook의 목표는 호스트의 그룹을 정의된 Ansible내에서 테스크로 불리는 역할(Role)에 매핑해주는 것 - name: 'Execute two commands on localhost' hosts: web_node1 tasks: - name: 'Execute a date command' command: date - name: 'Execute a command to display hosts file' command: 'cat /etc/hosts' Play name 1개 + 그룹에 속한 hosts - name: 'Execute two commands .. 2023. 6. 27. 이전 1 다음