cake-contrib / Cake_Git

Cake AddIn that extends Cake with Git features using LibGit2 and LibGit2Sharp

Home Page:https://cakebuild.net/extensions/cake-git

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Push to use deployment key

simonetino opened this issue · comments

I need to push to a private GitHub repository: the only I can do this today is by using the credentials of an actual GitHub user that has write access to the repository.

As the push is performed server side, it would be more scalable to be able to use GitHub deploy keys.
Ideally, it would be nice to have a Push alias which takes a key as input.

SSH isn't supported by the underlying LibGit2Sharp
There's an issue around SSH at libgit2/libgit2sharp#1422

Only atm is to use oauth tokens, which is tied to user and not repo
https://help.github.com/articles/git-automation-with-oauth-tokens/

If you want to scope it to a repo I would create a separate dedicated GH account with limited access.