1
0
mirror of synced 2025-12-22 03:16:52 -05:00
Commit Graph

10 Commits

Author SHA1 Message Date
James M. Greene
8771695531 Make the HEROKU_PRODUCTION_APP_NAME env var required for prod deployment (#21910) 2021-10-06 11:53:28 -05:00
James M. Greene
8d2e1ad577 Enable prod deployment via Actions (Take 2!) (#21852)
* Move concurrency control to top-level in prod deploy workflow

* Add 503 to the list of temporarily acceptable Heroku failure codes

* Add HEROKU_PRODUCTION_APP_NAME back into the prod deploy workflow
2021-10-01 13:37:46 -05:00
James M. Greene
7e954927e2 [DO NOT MERGE] Revert to no longer deploy to production via Actions (#21808)
* Update the production deployment workflow to target the main Heroku app

Without exposing our internal Heroku app name!

* Refactor the staging deployment script a bit to match more closely

* Use the HEROKU_PRODUCTION_APP_NAME Secret in the workflow

* Add a note about the newly required environment variable for production deployment into the local deploy script

* Add critical errors if the HEROKU_PRODUCTION_APP_NAME is missing

* Extract HEROKU_PRODUCTION_APP_NAME from process.env

* Revert the critical parts of PR #21807 to no longer deploy to prod via Actions

* Don't require HEROKU_PRODUCITON_APP_NAME
2021-09-29 15:29:53 -05:00
James M. Greene
90d030a41e Deploy to the primary production Heroku App via Actions (#21807)
* Update the production deployment workflow to target the main Heroku app

Without exposing our internal Heroku app name!

* Refactor the staging deployment script a bit to match more closely

* Use the HEROKU_PRODUCTION_APP_NAME Secret in the workflow

* Add a note about the newly required environment variable for production deployment into the local deploy script

* Add critical errors if the HEROKU_PRODUCTION_APP_NAME is missing

* Extract HEROKU_PRODUCTION_APP_NAME from process.env
2021-09-29 14:43:29 -05:00
James M. Greene
469e33cbb6 Allow Heroku 500 error codes while polling (#21795)
* Extract allowable Heroku error checks into a reusable function

* Add 500 to the list of allowable Heroku errors while polling
2021-09-28 21:00:03 +00:00
James M. Greene
1d0d782342 Production deploy script (#21768)
* Create a logic branch to deploy to production via a local script

* Ignore forceRebuild default value for production

* Add soft warnings for missing-but-not-critical env vars

* Only include the Preboot delay if the Fastly env vars are present

* Add some warning emojis ⚠️

* More emojis!

* Make FASTLY_* checks all independent

* Add more comments about additional env vars recommended for a local prod deployment
2021-09-27 22:17:21 +00:00
James M. Greene
deab27360c Announce if Heroku appears to be down (#21762) 2021-09-27 20:17:05 +00:00
James M. Greene
1024ede61d Explicitly unset the DOCUBOT_REPO_PAT Heroku config var when possible (#21751) 2021-09-27 18:22:02 +00:00
James M. Greene
a76f30e5f2 Move delay for Heroku Preboot to before marking deployment successful (#21736)
* Move delay for Heroku Preboot from post-deploy to pre-success

* Shorten arbitrary delay before first Fastly purge
2021-09-24 19:35:13 -05:00
Grace Park
9c9d47f508 Prod deployment workflow (#21223)
* add production deployment

* updating existing build

* remove state

* remove PR_URL and switch to main branch

* break out into build, prepare, and deploy

* update to download-artifact

* update staging to prod

* Actions production deployment redux (#21238)

* Simplify production deployment into a single Actions job

* Force esm to install

* Switch flag ordering to match staging deploy

* Use 'npm install' for the second installation to avoid deleting the prodDeps

* Apply Heroku upload fixes

* Include `.npmrc` file in builds to omit `optionalDeps`

* Remove download-artifact action

Co-authored-by: Grace Park <gracepark@github.com>

* Script updates to prod deployment (#21247)

* updating script to use latest sha

* changing back workflowRunLog

* remove line

* update error wording

* remove comment - using commit sha

* need release.id

* Update script/deployment/deploy-to-production.js

Co-authored-by: James M. Greene <JamesMGreene@github.com>

* remove hydro

* Update script/deployment/deploy-to-production.js

Co-authored-by: James M. Greene <JamesMGreene@github.com>

* Update .github/workflows/prod-build-deploy-pr.yml

Co-authored-by: James M. Greene <JamesMGreene@github.com>

* Update script/deployment/deploy-to-production.js

Co-authored-by: James M. Greene <JamesMGreene@github.com>

* Update script/deployment/deploy-to-production.js

Co-authored-by: James M. Greene <JamesMGreene@github.com>

* Update script/deployment/deploy-to-production.js

Co-authored-by: James M. Greene <JamesMGreene@github.com>

* updating spacing

* add 404/429 responses while polling Heroku API for prod

* removing nested ifs

* adding SOURCE_BLOB_URL

* update for early access

* add install dotenv

* need to add persist-credentials

* Testing GET request

* update request

* Rename workflow file to remove '-pr'

We are now triggering on pushes to 'main' rather than PR merges

* Remove the unnecessary workflow step to create a failure Status

Because the production deploy is done via a single workflow rather than a 2-part workflow chain, this is thankfully unnecessary

* Install all of the npm dependencies

We'll need them!

* Add the '-z' flag to 'tar' to gzip the tarball

* Pass the Heroku upload URL via env vars for security

Prevents potential injection attacks

* Log the deployment ID and log URL as deploy step outputs

* Take notice of Heroku polling resulting in failure statuses

* Add a note to consider waiting for Heroku Preboot

* Add a script and workflow step to purge Fastly

* update response to get sha

* Switch to Octokit functions instead of 'request' method

Co-authored-by: James M. Greene <JamesMGreene@github.com>
2021-09-24 16:09:08 +00:00