Skip to content

Instantly share code, notes, and snippets.

@svlasov
Forked from makmanalp/sshtest-playbook.yml
Created December 6, 2016 06:02
Show Gist options
  • Save svlasov/f3866a0e372ce1aafd016f5019683fbd to your computer and use it in GitHub Desktop.
Save svlasov/f3866a0e372ce1aafd016f5019683fbd to your computer and use it in GitHub Desktop.
SSH agent forwarding tester for ansible / vagrant
---
- hosts: all
sudo: no
tasks:
- shell: echo "Client= [$SSH_CLIENT] Sock= [$SSH_AUTH_SOCK]"
register: myecho
- debug: msg="{{myecho.stdout}}"
- shell: ssh-add -l
register: myecho
- debug: msg="{{myecho.stdout}}"
- shell: ssh -T -vvvv [email protected]
register: myecho
- debug: msg="{{myecho.stdout}}"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment