-
Notifications
You must be signed in to change notification settings - Fork 103
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mac - ssh-agent forwarding - ee container asks ssh key passphrase #1623
Comments
After a big web detour, it seems to be a MacOS+Docker thing (e.i docker/for-mac#410 ). Running manually a docker container by combining
Ansible-navigater is adding Adding the "mac" keyword on the title of this issue. |
@ajinkyau @cidrblock Can you please investigate this and determine if that is indeed a bug in navigator or just an environment specific issue related to docker on macos. Probably we would also have a similar issue with podman because its also works the same way (container host being VM). |
+1 |
Also running into this issue and would like to be able to use the EE approach with MacOS + Docker. |
We are also affected, we would like to use ansible-navigator but because of some Mac Users in the Team this is not possible due to this issue. |
I did notice an improvement when using podman instead of docker. If podman is an option for you, try switching from docker to podman and setting
|
Nope: I have the same issue here with podman: |
ISSUE TYPE
SUMMARY
ssh-agent forwarding in the ee container seems to be not working. It keeps asking for my passphrase on remote connections. For troubleshooting so far, I run an ansible task to
sleep 1000
and then exec in the ee container to run commands likessh-add -l
,env
etc.., or I exec in the ee docker image directly using the same options as ansible-navigator does.SSH_AUTH_SOCK
env variable is correctly passed in the ee and the socket is mounted:In the ee container:
but my key is not there:
I tried @timway's suggestion ansible/ansible-runner#1293 to add a docker option
--user root
but didn't help.ANSIBLE-NAVIGATOR VERSION
Running with Docker Desktop 4.23.0 on a Mac M1 + macOS 14 Sonoma
CONFIGURATION
LOG FILE
STEPS TO REPRODUCE
Use an image for execution environment and your ssh key with a passphrase.
EXPECTED RESULTS
As described in docs: https://github.com/ansible/ansible-navigator/blob/main/docs/faq.md#ssh-keys
The use of ssh-agent results in the simplest configuration and eliminates issues with SSH key passphrases when using ansible-navigator with execution environments.
ACTUAL RESULTS
ssh to remote hosts fails
ADDITIONAL INFORMATION
my
ansible.cfg
in the project dir:part of my
.ssh/config
The text was updated successfully, but these errors were encountered: