Skip to content

Commit

Permalink
feat: add base url as parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
BlackDark committed Dec 16, 2022
1 parent 98f5d7a commit 0e57db2
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 3 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ inputs:
privateKey:
description: The private key used to sign the JWT
required: true
baseUrl:
description: Optional base url for github requests
required: false
outputs:
token:
description: The generated RS256-signed JWT
Expand Down
3 changes: 2 additions & 1 deletion src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,9 @@ export async function run(): Promise<void> {
const appId = parseInt(getInput('appId'), 10)
const installationId = parseInt(getInput('installationId'), 10)
const privateKey = getInput('privateKey')
const baseUrl = getInput('baseUrl', {required: false})

const {token} = await getToken({appId, installationId, privateKey})
const {token} = await getToken({appId, installationId, privateKey, baseUrl})

setOutput('token', token)
} catch (error) {
Expand Down

0 comments on commit 0e57db2

Please sign in to comment.