Skip to content
This repository has been archived by the owner on Jan 27, 2019. It is now read-only.

Ssh protocol for dependencies downloads #25

Open
m0j0hn opened this issue Apr 2, 2017 · 0 comments
Open

Ssh protocol for dependencies downloads #25

m0j0hn opened this issue Apr 2, 2017 · 0 comments

Comments

@m0j0hn
Copy link

m0j0hn commented Apr 2, 2017

Hi,

Background: Our dependencies live in private repos on Github, and we use Git over ssh to retrieve them, using ssh-agent to proxy the key(s), so users do not need to manually provide keys when running Gradle. Typical manual Git clone command looks like:
"git clone ssh://git@github.com:organization/reponame.git"

When I add these dependencies to gradle-golang-plugin dependencies, it seems to always try to use https - is there some way to get gradle-golang-plugin to use SSH ?

(e.g., maybe I could do preliminary work of adding each remote dependency repo using "git remote add reponame ssh://git@github.com:organization/reponame.git" for each remote repo, and then gradle-golang-plugin would simply work? It doesn't seem to work this way currently, but maybe this would be an easy way to enable this)

(Alternatively (and preferred) would be to allow users to specify protocol in the dependencies, e.g.,
build "ssh://git@github.com:organization/repo")

(Another alternative might be to enhance the vcsRepositoryProvider directive somehow to allow this, maybe add 2 more optional arguments like protocol and user, so syntax might be:
vcsRepositoryProvider('', '', '', '', '', '')
// Example:
// vcsRepositoryProvider('git', 'github.com/', 'GitHub', 'ssh', 'git', '^(?github\.com[/:][A-Za-z0-9_.\-]+/[A-Za-z0-9_.\-]+)(?/[A-Za-z0-9_.\-]+)*$')
}

Look forward to your response!
Thanks!
-- m0j0hn

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

No branches or pull requests

1 participant