Last active
October 7, 2019 18:11
-
-
Save bobquest33/70f60f22f97bd69ca3da9337506aa4e2 to your computer and use it in GitHub Desktop.
Ansible Playbook for setting and checking if time reflects based on timezone
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- hosts: raspi | |
become: yes | |
vars: | |
timezone_zone: Asia/Kolkata # valid tz database string | |
roles: | |
- role: anxs.timezone | |
post_tasks: | |
- name: get current time | |
shell: date | |
register: tz_op | |
- debug: msg="{{ ansible_default_ipv4.address }} - {{ tz_op.stdout }}" | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment