1
0
mirror of synced 2025-12-21 02:46:50 -05:00

Do not use build.status as a looping condition for Heroku deployment (#21909)

* Do not use `build.status` of 'pending' as a looping condition for Heroku deployment
* Don't wait for `appSetup.status` either
* Fix incorrect Octokit method usage in local deploy script
* Bump the number of allowable errors from 5 to 10
* More logging!
* Add an environment variable for easily increasing the number of allowed Heroku failures per phase of polling
This commit is contained in:
James M. Greene
2021-10-06 12:57:30 -05:00
committed by GitHub
parent 7f7f06e2ba
commit bb0455962e
5 changed files with 36 additions and 8 deletions

View File

@@ -234,7 +234,7 @@ async function deployStaging({ owner, repo, pullNumber, forceRebuild = false, de
pullRequest,
})
} else {
await octokit.repos.createStatus({
await octokit.repos.createCommitStatus({
owner,
repo,
sha: pullRequest.head.sha,
@@ -249,7 +249,7 @@ async function deployStaging({ owner, repo, pullNumber, forceRebuild = false, de
forceRebuild,
})
await octokit.repos.createStatus({
await octokit.repos.createCommitStatus({
owner,
repo,
sha: pullRequest.head.sha,
@@ -264,7 +264,7 @@ async function deployStaging({ owner, repo, pullNumber, forceRebuild = false, de
console.error(error)
if (!destroy) {
await octokit.repos.createStatus({
await octokit.repos.createCommitStatus({
owner,
repo,
sha: pullRequest.head.sha,