diff --git a/README.md b/README.md index 941d5538..3559d745 100644 --- a/README.md +++ b/README.md @@ -17,15 +17,15 @@ For more information, see: [What is a builder?](https://buildpacks.io/docs/conce ## Available images > [!WARNING] -> The `heroku/buildpacks:*` and `heroku/builder-classic:*` builder image variants are deprecated, +> The `heroku/buildpacks:*` and `heroku/builder-classic:*` builder image variants have been sunset, > since they use classic Heroku buildpacks shimmed for compatibility with the CNB specification, > rather than Heroku's next-generation Cloud Native Buildpacks. | Builder Image | Base Build Image | Base Run Image | Lifecycle Version | Buildpack Types | Status | |-----------------------------------------------------|---------------------------------------------|---------------------------------------|-------------------|------------------|-------------| | [`heroku/buildpacks:18`][buildpacks-tags] | [`heroku/heroku:18-cnb-build`][heroku-tags] | [`heroku/heroku:18-cnb`][heroku-tags] | 0.16.1 | Shimmed + Native | End-of-life | -| [`heroku/buildpacks:20`][buildpacks-tags] | [`heroku/heroku:20-cnb-build`][heroku-tags] | [`heroku/heroku:20-cnb`][heroku-tags] | 0.17.4 | Shimmed + Native | Deprecated | -| [`heroku/builder-classic:22`][builder-classic-tags] | [`heroku/heroku:22-cnb-build`][heroku-tags] | [`heroku/heroku:22-cnb`][heroku-tags] | 0.17.4 | Shimmed | Deprecated | +| [`heroku/buildpacks:20`][buildpacks-tags] | [`heroku/heroku:20-cnb-build`][heroku-tags] | [`heroku/heroku:20-cnb`][heroku-tags] | 0.17.4 | Shimmed + Native | End-of-life | +| [`heroku/builder-classic:22`][builder-classic-tags] | [`heroku/heroku:22-cnb-build`][heroku-tags] | [`heroku/heroku:22-cnb`][heroku-tags] | 0.17.4 | Shimmed | End-of-life | | [`heroku/builder:20`][builder-tags] | [`heroku/heroku:20-cnb-build`][heroku-tags] | [`heroku/heroku:20-cnb`][heroku-tags] | 0.19.0 | Native | Available | | [`heroku/builder:22`][builder-tags] | [`heroku/heroku:22-cnb-build`][heroku-tags] | [`heroku/heroku:22-cnb`][heroku-tags] | 0.19.0 | Native | Recommended | diff --git a/builder-classic-22/builder.toml b/builder-classic-22/builder.toml index e379127f..3a67f502 100644 --- a/builder-classic-22/builder.toml +++ b/builder-classic-22/builder.toml @@ -59,6 +59,9 @@ version = "0.17.4" uri = "https://cnb-shim.herokuapp.com/v1/heroku/scala?version=0.0.0&name=Heroku+Scala+(Shimmed)" [[order]] + [[order.group]] + id = "heroku/builder-eol-warning" + version = "2.0.0" [[order.group]] id = "heroku/ruby" version = "0.0.0" @@ -66,11 +69,11 @@ version = "0.17.4" id = "heroku/procfile" version = "2.0.2" optional = true - [[order.group]] - id = "heroku/builder-eol-warning" - version = "1.0.0" [[order]] + [[order.group]] + id = "heroku/builder-eol-warning" + version = "2.0.0" [[order.group]] id = "heroku/clojure" version = "0.0.0" @@ -78,11 +81,11 @@ version = "0.17.4" id = "heroku/procfile" version = "2.0.2" optional = true - [[order.group]] - id = "heroku/builder-eol-warning" - version = "1.0.0" [[order]] + [[order.group]] + id = "heroku/builder-eol-warning" + version = "2.0.0" [[order.group]] id = "heroku/python" version = "0.0.0" @@ -90,11 +93,11 @@ version = "0.17.4" id = "heroku/procfile" version = "2.0.2" optional = true - [[order.group]] - id = "heroku/builder-eol-warning" - version = "1.0.0" [[order]] + [[order.group]] + id = "heroku/builder-eol-warning" + version = "2.0.0" [[order.group]] id = "heroku/java" version = "0.0.0" @@ -102,11 +105,11 @@ version = "0.17.4" id = "heroku/procfile" version = "2.0.2" optional = true - [[order.group]] - id = "heroku/builder-eol-warning" - version = "1.0.0" [[order]] + [[order.group]] + id = "heroku/builder-eol-warning" + version = "2.0.0" [[order.group]] id = "heroku/gradle" version = "0.0.0" @@ -114,11 +117,11 @@ version = "0.17.4" id = "heroku/procfile" version = "2.0.2" optional = true - [[order.group]] - id = "heroku/builder-eol-warning" - version = "1.0.0" [[order]] + [[order.group]] + id = "heroku/builder-eol-warning" + version = "2.0.0" [[order.group]] id = "heroku/scala" version = "0.0.0" @@ -126,11 +129,11 @@ version = "0.17.4" id = "heroku/procfile" version = "2.0.2" optional = true - [[order.group]] - id = "heroku/builder-eol-warning" - version = "1.0.0" [[order]] + [[order.group]] + id = "heroku/builder-eol-warning" + version = "2.0.0" [[order.group]] id = "heroku/php" version = "0.0.0" @@ -138,11 +141,11 @@ version = "0.17.4" id = "heroku/procfile" version = "2.0.2" optional = true - [[order.group]] - id = "heroku/builder-eol-warning" - version = "1.0.0" [[order]] + [[order.group]] + id = "heroku/builder-eol-warning" + version = "2.0.0" [[order.group]] id = "heroku/go" version = "0.0.0" @@ -150,11 +153,11 @@ version = "0.17.4" id = "heroku/procfile" version = "2.0.2" optional = true - [[order.group]] - id = "heroku/builder-eol-warning" - version = "1.0.0" [[order]] + [[order.group]] + id = "heroku/builder-eol-warning" + version = "2.0.0" [[order.group]] id = "heroku/nodejs" version = "0.0.0" @@ -162,6 +165,3 @@ version = "0.17.4" id = "heroku/procfile" version = "2.0.2" optional = true - [[order.group]] - id = "heroku/builder-eol-warning" - version = "1.0.0" diff --git a/builder-classic-22/end-of-life-buildpack/bin/build b/builder-classic-22/end-of-life-buildpack/bin/build index 8f61a62e..33e84223 100755 --- a/builder-classic-22/end-of-life-buildpack/bin/build +++ b/builder-classic-22/end-of-life-buildpack/bin/build @@ -2,6 +2,10 @@ set -euo pipefail +ENV_DIR="${2}/env" +ENV_VAR_NAME='ALLOW_EOL_SHIMMED_BUILDER' +ALLOW_BUILD="$(cat "${ENV_DIR}/${ENV_VAR_NAME}" 2> /dev/null || true)" + ANSI_RED="\033[1;31m" ANSI_RESET="\033[0m" @@ -15,10 +19,20 @@ function display_error() { echo >&2 } -display_error "$(cat <<'EOF' +if [[ "${ALLOW_BUILD}" == "1" ]]; then + MSG_PREFIX="WARNING" + MSG_FOOTER="Allowing the build to continue since ${ENV_VAR_NAME} is set." + EXIT_CODE=0 +else + MSG_PREFIX="ERROR" + MSG_FOOTER="To ignore this error, set the env var ${ENV_VAR_NAME} to 1." + EXIT_CODE=1 +fi + +display_error "$(cat < /dev/null || true)" + ANSI_RED="\033[1;31m" ANSI_RESET="\033[0m" @@ -15,10 +19,20 @@ function display_error() { echo >&2 } -display_error "$(cat <<'EOF' +if [[ "${ALLOW_BUILD}" == "1" ]]; then + MSG_PREFIX="WARNING" + MSG_FOOTER="Allowing the build to continue since ${ENV_VAR_NAME} is set." + EXIT_CODE=0 +else + MSG_PREFIX="ERROR" + MSG_FOOTER="To ignore this error, set the env var ${ENV_VAR_NAME} to 1." + EXIT_CODE=1 +fi + +display_error "$(cat <