인프라/앤서블(Ansible)
[Ansible] ansible apt update playbook
IT맥구리나스
2022. 7. 20. 18:42
ansible로 우분투 패키지 설치전 apt update를 수행하고 싶을때 아래와 같이 수행한다.
---
- name: install amsclient
hosts: all
become: yes
vars:
ansible_become_password: "{{ sudopasswd }}"
tasks:
- name: apt install ipa-client
apt:
update_cache: yes
force_apt_get: yes
cache_valid_time: 3600
앤서블 우분투 apt 업데이트
앤서블 ubuntu apt udpate
ansible ubuntu apt udpate
반응형