2022-01-24 01:48:58 +00:00
|
|
|
---
|
2024-02-12 01:09:10 +00:00
|
|
|
- hosts: lab
|
2022-01-24 01:48:58 +00:00
|
|
|
tasks:
|
|
|
|
- name: Normal Echo
|
|
|
|
command: echo Quick test of an echo
|
|
|
|
register: normal_echo
|
|
|
|
|
|
|
|
- debug:
|
|
|
|
var: normal_echo.stdout
|
|
|
|
|
|
|
|
- name: Checking Sudo access
|
|
|
|
become: yes
|
|
|
|
command: echo One more test with sudo this time
|
|
|
|
register: sudo_echo
|
|
|
|
|
|
|
|
- debug:
|
|
|
|
var: sudo_echo.stdout
|
|
|
|
- debug:
|
|
|
|
var: sudo_echo.stderr
|