-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Closed
Description
Description
As a developer I want docker-py
to load the identity file according to my setting specified in ~/.ssh/config
, not only the "default" id_rsa
file.
Example
I have a ~/.ssh/config
file with contents:
Host myHost
User myUser
HostName myIp
IdentityFile C:/Users/me/.ssh/id_rsa_custom_file
IdentitiesOnly yes
Now I would like docker-py
to pick up C:/Users/me/.ssh/id_rsa_custom_file
for trying to connect to the remote host (For example when I want to run docker-compose -H "ssh://myHost" ps
. However right now it does not.
When I rename C:/Users/me/.ssh/id_rsa_custom_file
to C:/Users/me/.ssh/id_rsa
it works just fine. However this is not an option for me since I have multiple identity files and hosts that I want to use.
Proposal
Add something like this to the sshcon.py
:
if 'identityfile' in host_config:
self.ssh_params['key_filename '] = host_config['identityfile']
HaaLeo and apatrushev
Metadata
Metadata
Assignees
Labels
No labels