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

fix: get ssh username from ~/.ssh/config, if not specified in uri #1143

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

pnsafonov
Copy link

Fix allows to use

provider "libvirt" {
 uri ="qemu+ssh://mn0/system?no_verify=1&sshauth=privkey"
}

in addition to:

provider "libvirt" {
 uri = "qemu+ssh://p.safonov@mn0/system?no_verify=1&sshauth=privkey"
}

Then username is specified in ~/.ssh/config:

Host micronode0 mn0
    User p.safonov # read this string
    Port 22
    HostName 10.128.4.38
    IdentityFile /home/pavel/.ssh/server/pp/pp_mn0
    IdentitiesOnly yes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant