diff --git a/README.md b/README.md index f4cd0fa5..4a91b52c 100644 --- a/README.md +++ b/README.md @@ -10,10 +10,10 @@ The builder images use Heroku's [stack images](https://github.com/heroku/stack-i | Builder Image | Base Image | Status | |-----------------------------------------------------|---------------------------------------------|-------------| | [`heroku/buildpacks:18`][buildpacks-tags] | [`heroku/heroku:18-cnb-build`][heroku-tags] | End-of-life | -| [`heroku/buildpacks:20`][buildpacks-tags] | [`heroku/heroku:20-cnb-build`][heroku-tags] | Available | +| [`heroku/buildpacks:20`][buildpacks-tags] | [`heroku/heroku:20-cnb-build`][heroku-tags] | Deprecated | | [`heroku/builder:20`][builder-tags] | [`heroku/heroku:20-cnb-build`][heroku-tags] | Available | | [`heroku/builder:22`][builder-tags] | [`heroku/heroku:22-cnb-build`][heroku-tags] | Recommended | -| [`heroku/builder-classic:22`][builder-classic-tags] | [`heroku/heroku:22-cnb-build`][heroku-tags] | Available | +| [`heroku/builder-classic:22`][builder-classic-tags] | [`heroku/heroku:22-cnb-build`][heroku-tags] | Deprecated | [`heroku/builder`][builder-tags] builder images feature Heroku's native Cloud Native Buildpacks. These buildpacks are optimized and make use of many CNB features. These builder images support Go, Java (Maven, Gradle), Node.js, PHP, Python, Ruby, Scala and Typescript codebases. diff --git a/builder-classic-22/builder.toml b/builder-classic-22/builder.toml index d08eefba..ec6a5fbe 100644 --- a/builder-classic-22/builder.toml +++ b/builder-classic-22/builder.toml @@ -8,6 +8,10 @@ run-image = "heroku/heroku:22-cnb" [lifecycle] version = "0.17.2" +[[buildpacks]] + id = "heroku/builder-eol-warning" + uri = "./end-of-life-buildpack/" + [[buildpacks]] id = "heroku/clojure" uri = "https://cnb-shim.herokuapp.com/v1/heroku/clojure?version=0.0.0&name=Heroku+Clojure+(Shimmed)" @@ -52,88 +56,106 @@ version = "0.17.2" [[order.group]] id = "heroku/ruby" version = "0.0.0" - [[order.group]] 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/clojure" version = "0.0.0" - [[order.group]] 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/python" version = "0.0.0" - [[order.group]] 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/java" version = "0.0.0" - [[order.group]] 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/gradle" version = "0.0.0" - [[order.group]] 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/scala" version = "0.0.0" - [[order.group]] 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/php" version = "0.0.0" - [[order.group]] 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/go" version = "0.0.0" - [[order.group]] 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/nodejs" version = "0.0.0" - [[order.group]] 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 new file mode 100755 index 00000000..f04f750b --- /dev/null +++ b/builder-classic-22/end-of-life-buildpack/bin/build @@ -0,0 +1,36 @@ +#!/usr/bin/env bash + +set -euo pipefail + +function echo_stderr() { + local ansi_red="\033[1;31m" + local ansi_reset="\033[0m" + echo -e "\n${ansi_red}${1}${ansi_reset}\n" >&2 +} + +read -r -d '' EOL_MESSAGE <<'EOF' || true +####################################################################### + +WARNING: This builder image (heroku/builder-classic:22) is deprecated, +since it uses legacy shimmed classic Heroku buildpacks, rather than +Heroku's next-generation Cloud Native Buildpacks. + +As such, this image is no longer supported and will soon stop receiving +security updates. + +Please switch to one of our newer 'heroku/builder:*' builder images, +such as 'heroku/builder:22': +https://github.com/heroku/cnb-builder-images#heroku-cnb-builder-images + +If you are using the Pack CLI, you will need to adjust your '--builder' +CLI argument, or else change the default builder configuration: +https://buildpacks.io/docs/tools/pack/cli/pack_config_default-builder/ + +If you are using a third-party platform to deploy your app, check their +documentation for how to adjust the builder image used for your build. + +####################################################################### +EOF + +echo_stderr "${EOL_MESSAGE}" +exit 0 diff --git a/builder-classic-22/end-of-life-buildpack/bin/detect b/builder-classic-22/end-of-life-buildpack/bin/detect new file mode 100755 index 00000000..0fdcf091 --- /dev/null +++ b/builder-classic-22/end-of-life-buildpack/bin/detect @@ -0,0 +1,3 @@ +#!/usr/bin/env bash + +exit 0 diff --git a/builder-classic-22/end-of-life-buildpack/buildpack.toml b/builder-classic-22/end-of-life-buildpack/buildpack.toml new file mode 100644 index 00000000..93e88ba6 --- /dev/null +++ b/builder-classic-22/end-of-life-buildpack/buildpack.toml @@ -0,0 +1,8 @@ +api = "0.9" + +[buildpack] + id = "heroku/builder-eol-warning" + version = "1.0.0" + +[[stacks]] + id = "*" diff --git a/buildpacks-20/builder.toml b/buildpacks-20/builder.toml index 73f76281..af7e52ea 100644 --- a/buildpacks-20/builder.toml +++ b/buildpacks-20/builder.toml @@ -8,6 +8,10 @@ run-image = "heroku/heroku:20-cnb" [lifecycle] version = "0.17.2" +[[buildpacks]] + id = "heroku/builder-eol-warning" + uri = "./end-of-life-buildpack/" + [[buildpacks]] id = "heroku/go" uri = "https://cnb-shim.herokuapp.com/v1/heroku/go?version=0.0.0&name=Heroku+Go+(Shimmed)" @@ -52,6 +56,9 @@ version = "0.17.2" id = "heroku/procfile" version = "2.0.2" optional = true + [[order.group]] + id = "heroku/builder-eol-warning" + version = "1.0.0" [[order]] [[order.group]] @@ -61,6 +68,9 @@ version = "0.17.2" id = "heroku/procfile" version = "2.0.2" optional = true + [[order.group]] + id = "heroku/builder-eol-warning" + version = "1.0.0" [[order]] [[order.group]] @@ -70,6 +80,9 @@ version = "0.17.2" id = "heroku/procfile" version = "2.0.2" optional = true + [[order.group]] + id = "heroku/builder-eol-warning" + version = "1.0.0" [[order]] [[order.group]] @@ -79,6 +92,9 @@ version = "0.17.2" id = "heroku/procfile" version = "2.0.2" optional = true + [[order.group]] + id = "heroku/builder-eol-warning" + version = "1.0.0" [[order]] [[order.group]] @@ -88,6 +104,9 @@ version = "0.17.2" id = "heroku/procfile" version = "2.0.2" optional = true + [[order.group]] + id = "heroku/builder-eol-warning" + version = "1.0.0" [[order]] [[order.group]] @@ -97,6 +116,9 @@ version = "0.17.2" id = "heroku/procfile" version = "2.0.2" optional = true + [[order.group]] + id = "heroku/builder-eol-warning" + version = "1.0.0" [[order]] [[order.group]] @@ -106,3 +128,6 @@ version = "0.17.2" id = "heroku/procfile" version = "2.0.2" optional = true + [[order.group]] + id = "heroku/builder-eol-warning" + version = "1.0.0" diff --git a/buildpacks-20/end-of-life-buildpack/bin/build b/buildpacks-20/end-of-life-buildpack/bin/build new file mode 100755 index 00000000..17cb6181 --- /dev/null +++ b/buildpacks-20/end-of-life-buildpack/bin/build @@ -0,0 +1,36 @@ +#!/usr/bin/env bash + +set -euo pipefail + +function echo_stderr() { + local ansi_red="\033[1;31m" + local ansi_reset="\033[0m" + echo -e "\n${ansi_red}${1}${ansi_reset}\n" >&2 +} + +read -r -d '' EOL_MESSAGE <<'EOF' || true +####################################################################### + +WARNING: This builder image (heroku/buildpacks:20) is deprecated, +since it uses legacy shimmed classic Heroku buildpacks, rather than +Heroku's next-generation Cloud Native Buildpacks. + +As such, this image is no longer supported and will soon stop receiving +security updates. + +Please switch to one of our newer 'heroku/builder:*' builder images, +such as 'heroku/builder:22': +https://github.com/heroku/cnb-builder-images#heroku-cnb-builder-images + +If you are using the Pack CLI, you will need to adjust your '--builder' +CLI argument, or else change the default builder configuration: +https://buildpacks.io/docs/tools/pack/cli/pack_config_default-builder/ + +If you are using a third-party platform to deploy your app, check their +documentation for how to adjust the builder image used for your build. + +####################################################################### +EOF + +echo_stderr "${EOL_MESSAGE}" +exit 0 diff --git a/buildpacks-20/end-of-life-buildpack/bin/detect b/buildpacks-20/end-of-life-buildpack/bin/detect new file mode 100755 index 00000000..0fdcf091 --- /dev/null +++ b/buildpacks-20/end-of-life-buildpack/bin/detect @@ -0,0 +1,3 @@ +#!/usr/bin/env bash + +exit 0 diff --git a/buildpacks-20/end-of-life-buildpack/buildpack.toml b/buildpacks-20/end-of-life-buildpack/buildpack.toml new file mode 100644 index 00000000..93e88ba6 --- /dev/null +++ b/buildpacks-20/end-of-life-buildpack/buildpack.toml @@ -0,0 +1,8 @@ +api = "0.9" + +[buildpack] + id = "heroku/builder-eol-warning" + version = "1.0.0" + +[[stacks]] + id = "*"