ss
This commit is contained in:
19
update.yml
19
update.yml
@@ -1,11 +1,20 @@
|
|||||||
- hosts: all
|
- hosts: all
|
||||||
become: true
|
become: true
|
||||||
become_method: sudo
|
|
||||||
become_user: root
|
|
||||||
tasks:
|
tasks:
|
||||||
- name: get user
|
- name: Update and upgrade apt packages
|
||||||
# uses_shell: true
|
apt:
|
||||||
ansible.builtin.shell: whoami
|
upgrade: yes
|
||||||
|
update_cache: yes
|
||||||
|
cache_valid_time: 86400
|
||||||
|
|
||||||
|
# - hosts: all
|
||||||
|
# become: true
|
||||||
|
# become_method: sudo
|
||||||
|
# become_user: root
|
||||||
|
# tasks:
|
||||||
|
# - name: get user
|
||||||
|
# # uses_shell: true
|
||||||
|
# ansible.builtin.shell: whoami
|
||||||
|
|
||||||
|
|
||||||
# - name: Run whoami without become.
|
# - name: Run whoami without become.
|
||||||
|
|||||||
Reference in New Issue
Block a user