Set baseUrl for Octokit to make it work on GitHub Enterprise Server

This commit is contained in:
Paul Loberg
2024-09-27 10:41:01 +02:00
parent 1ff3075b60
commit 4a60710ed8

View File

@@ -31,7 +31,7 @@ async function setup() {
if (version.length === 0) {
// If no version is specified, the latest version is used by default.
const token = core.getInput('token', {required: true});
const octokit = getOctokit(token);
const octokit = getOctokit(token, {baseUrl: 'https://api.github.com'});
const release = await octokit.rest.repos.getLatestRelease({
owner: 'mozilla',
repo: 'sccache'