Skip to content
This repository was archived by the owner on Sep 11, 2020. It is now read-only.
This repository was archived by the owner on Sep 11, 2020. It is now read-only.

Usage with a host alias set ssh config #629

@artushin

Description

@artushin

I'm getting a DNS resolution error to github when I have an alias for a particular remote origin url.

For example, let's say I have two git configs:

remote.origin.url=git@git1:user1/foo
remote.origin.url=git@git2:user2/bar

These have corresponding ssh configs:

Host git1
Hostname github.com
IdentityFile ~/.ssh/foo
User user1

Host git2
Hostname github.com
IdentityFile ~/.ssh/bar
User user2

Operations using go-git (I've only tried Pull but I assume others too), don't respect the ssh configs and fail with dial tcp: lookup git1 on 169.254.169.254:53: no such host. I'm not passing an Auth into the PullOptions. Am I doing something wrong or is this expected?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions