Skip to content
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

Enhancement: Authentication Should Support ssh config file #416

Closed
darkn3rd opened this issue Apr 26, 2018 · 6 comments
Closed

Enhancement: Authentication Should Support ssh config file #416

darkn3rd opened this issue Apr 26, 2018 · 6 comments
Labels
Feature New features and improvements.

Comments

@darkn3rd
Copy link

darkn3rd commented Apr 26, 2018

For ssh support, I wish I could use ssh-configuration file. Vagrant is one use case I would use this:

vagrant ssh-config > ssh-config
bolt command run $command -F ssh-config web-01.dev

Net::SSH::Config support this with load method:

@nicklewis
Copy link
Contributor

This should be working already. If not, there might be a bug. What are you trying to use in the ssh config and what isn't working?

@darkn3rd
Copy link
Author

darkn3rd commented Apr 26, 2018

I don't see an option for this:

https://github.com/puppetlabs/bolt/blob/master/lib/bolt/cli.rb#L165-L189

@nicklewis
Copy link
Contributor

Ah yes, it's done automatically and only uses the default ssh-config file. We certainly could add the option to specify a different ssh-config.

@darkn3rd
Copy link
Author

Vagrant users would be very happy. I dynamically generate these for my own bootstrap process in dev environments using vagrant, google cloud, or AWS. I can cat them to my ~/.ssh/config, but then it would be difficult to rip them out (instr + gsub hackery) when I remove the boxes.

@nicklewis
Copy link
Contributor

If you have SSH > 7.3, you can use the Include directive in ssh-config. So you could add something like Include config.d/* and write your environment-specific files to ~/.ssh/config.d/<filename>. That's a workaround, but it seems like it might work, if the version of SSH supports it.

@darkn3rd
Copy link
Author

darkn3rd commented Apr 26, 2018

My local development environment doesn't have it (Ubuntu 16.04)

$ lsb_release -cs
xenial
$ ssh -V
OpenSSH_7.2p2 Ubuntu-4ubuntu2.4, OpenSSL 1.0.2g  1 Mar 2016

A lot of systems out there, run Ubuntu 14.04, such as bastion host workstation.

@MikaelSmith MikaelSmith added the Feature New features and improvements. label Dec 7, 2018
@adreyer adreyer closed this as completed Sep 25, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature New features and improvements.
Projects
None yet
Development

No branches or pull requests

4 participants