Skip to content

Commit 1fafb87

Browse files
committed
Improve readme
1 parent c9fd18f commit 1fafb87

File tree

1 file changed

+18
-1
lines changed

1 file changed

+18
-1
lines changed

README.md

Lines changed: 18 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,20 @@
11
# ssh-private-key-buildpack
22

3-
Configure ssh to use provided key in `SSH_KEY` environment variable.
3+
A heroku buildpack for setting the ssh private key as part of the application build. It's meant to be used with [heroku-buildpack-multi](https://github.com/heroku/heroku-buildpack-multi), before other buildpacks which require the key to be present, like installing private `npm` modules from `github`.
4+
5+
# Example usage
6+
7+
Upload the private key to heroku (note that the key needs to be base64 encoded).
8+
9+
```
10+
heroku config:set SSH_KEY=$(cat ~/.ssh/id_rsa | base64)
11+
```
12+
13+
Add a `.buildpacks` file (used by `heroku-buildpack-multi`) which contains this and the default node.js buildpack.
14+
15+
```
16+
https://github.com/debitoor/ssh-private-key-buildpack.git#v1.0.0
17+
https://github.com/heroku/heroku-buildpack-nodejs.git#v75
18+
```
19+
20+
Now as long as the public key is present on github and the user has the correct permissions, it's possible to install `npm` modules from private `githup` repositories.

0 commit comments

Comments
 (0)