Does anyone know a way to store an ssh passphrase during a playbook run? All nodes have the same ssh key/passphrase. I just don't want to type the same passphrase 100 times during the playbook run. Is there any way to do this with passphrases?
--
You received this message because you are subscribed to the Google Groups "Ansible Project" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ansible-proje...@googlegroups.com.
To post to this group, send email to ansible...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/0560d800-ebe4-4dd2-9bd7-b8a0f53da9fd%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
# Configure ssh-agent (begin)SSH_ENV="$HOME/.ssh/environment"function start_agent { echo "Initializing new SSH agent..." /usr/bin/ssh-agent |sed 's/^echo/#echo/' > "${SSH_ENV}" echo succeeded chmod 600 "${SSH_ENV}" . "${SSH_ENV}" > /dev/null /usr/bin/ssh-add ~/.ssh/$(whoami);}
# Source SSH settings, if requiredif [ -f "${SSH_ENV}" ]; then . "${SSH_ENV}" > /dev/null ps -ef |grep ${SSH_AGENT_PID} | grep ssh-agent$ > /dev/null || { start_agent; }else start_agent;fi# Configure ssh-agent (end)