forked from pry0cc/axiom
-
Notifications
You must be signed in to change notification settings - Fork 75
Open
Description
Background:
- using the latest ax version (ax update says it is fine)
- using Digital Ocean
- I have several ssh private keys for different purposes
Problem
When I try to connect to my fleet instances I receive an error message:
ax ssh <targetinstance>
Received disconnect from xxx.xxx.xxx.xx port 2266:2: Too many authentication failures
Disconnected from xxx.xxx.xxx.xx port 2266
This is usually a clear indication that ssh is trying all my private keys before it reaches the one configured in ~/.axiom/axiom.json. I was able to confirm this by removing all my keys from the ssh-agent, which results in axiom connecting normally.
Workaround
I managed to fix the problem by:
ax ssh --just-generate(to generate ~/.axiom/.sshconfig)ax ssh --just-generate cache(to prevent ax from overwriting my modified config)- Modify ~/.axiom/.sshconfig by adding:
IdentitiesOnly yesright below the line that saysIdentityFile - Retry
ax ssh <targetinstance>this time with success
Suggested fix
Since ax is using a specific pubkey anyway, it might make sense to add that IdentitiesOnly yes to .sshconfig by default.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels