[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
This commit is contained in:
@@ -64,9 +64,16 @@ export default async function deployToProduction({
|
||||
let deploymentId = null
|
||||
let logUrl = workflowRunLog
|
||||
|
||||
const appName = process.env.HEROKU_PRODUCTION_APP_NAME
|
||||
const environment = 'production'
|
||||
const homepageUrl = 'https://docs.github.com/'
|
||||
let appName, environment, homepageUrl
|
||||
if (process.env.HEROKU_PRODUCTION_APP_NAME) {
|
||||
appName = process.env.HEROKU_PRODUCTION_APP_NAME
|
||||
environment = 'production'
|
||||
homepageUrl = 'https://docs.github.com/'
|
||||
} else {
|
||||
appName = 'help-docs-prod-gha'
|
||||
environment = appName
|
||||
homepageUrl = `https://${appName}.herokuapp.com/`
|
||||
}
|
||||
|
||||
try {
|
||||
const title = `branch '${branch}' at commit '${sha}' in the '${environment}' environment`
|
||||
|
||||
Reference in New Issue
Block a user