View a vault file

Show the decrypted contents of a vault file; the file itself stays encrypted

ansible-vault view group_vars/all/vault.yml

tool
ansible56 commands
tags
ansiblesecurity

More ansible commands

  • ansible all -m copy -a 'src=./nginx.conf dest=/etc/nginx/nginx.conf owner=root mode=0644' -i inventory.ini

    Copy a local file to all hosts with a set owner and mode

  • ansible webservers -m service -a 'name=nginx state=restarted' -b -i inventory.ini

    Restart nginx on all webservers ad-hoc, with privilege escalation (-b)

  • ansible-inventory -i inventory.ini --graph

    Show the inventory group hierarchy as a tree

  • molecule test -s default

    Run the full Molecule test: create, converge, verify, destroy

  • ansible all -i inventory.ini -m ping

    Check SSH access to all hosts in the inventory

all 56 ansible commands