Read private key as byte array
This commit is contained in:
parent
b28529ca80
commit
77b8be9968
1 changed files with 1 additions and 1 deletions
|
@ -14,7 +14,7 @@ import (
|
||||||
|
|
||||||
// Wrap the shared transport for use with the integration ID and authenticating with installation ID.
|
// Wrap the shared transport for use with the integration ID and authenticating with installation ID.
|
||||||
var privateKey = os.Getenv("privateKey")
|
var privateKey = os.Getenv("privateKey")
|
||||||
var itr, _ = ghinstallation.NewKeyFromFile(http.DefaultTransport, 381312, 41105280, privateKey)
|
var itr, _ = ghinstallation.New(http.DefaultTransport, 381312, 41105280, []byte(privateKey))
|
||||||
|
|
||||||
// Use installation transport with client.
|
// Use installation transport with client.
|
||||||
var client = github.NewClient(&http.Client{Transport: itr})
|
var client = github.NewClient(&http.Client{Transport: itr})
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue