Skip to content

Commit

Permalink
Add heroku/builder:24 as a trusted + suggested builder
Browse files Browse the repository at this point in the history
We have just completed our new `heroku/builder:24` builder,
which is based upon Ubuntu 24.04 and is also our first
multi-architecture (AMD64+ARM64) builder.

As such, I have:
- Added `heroku/builder:24` as a trusted+suggested builder
- Changed the existing `heroku/builder:22` builder entry so
  that it is now just trusted, and not also suggested (since we
  want to encourage users to use the newer builder, especially
  since it's now multi-arch).
- Re-synced the builder description metadata here with what's in
  our `builder.toml` configs. (The descriptions in this repo are
  what gets used in offline mode, when Pack CLI can't pull the
  latest image description from the image labels on the registry.)

See:
heroku/cnb-builder-images#534
https://github.com/heroku/cnb-builder-images/blob/main/builder-20/builder.toml
https://github.com/heroku/cnb-builder-images/blob/main/builder-22/builder.toml
https://github.com/heroku/cnb-builder-images/blob/main/builder-24/builder.toml

Signed-off-by: Ed Morley <[email protected]>
  • Loading branch information
edmorley committed Jun 5, 2024
1 parent 98f0eb4 commit 6c4f1d9
Show file tree
Hide file tree
Showing 7 changed files with 21 additions and 8 deletions.
2 changes: 1 addition & 1 deletion acceptance/assertions/output.go
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ func (o OutputAssertionManager) IncludesPrefixedGoogleBuilder() {
}

var herokuBuilders = []string{
"heroku/builder:22",
"heroku/builder:24",
}

func (o OutputAssertionManager) IncludesHerokuBuilders() {
Expand Down
13 changes: 10 additions & 3 deletions internal/builder/known_builder.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,22 @@ var KnownBuilders = []KnownBuilder{
},
{
Vendor: "Heroku",
Image: "heroku/builder:22",
DefaultDescription: "Heroku-22 (Ubuntu 22.04) base image with buildpacks for Go, Java, Node.js, PHP, Python, Ruby & Scala",
Image: "heroku/builder:24",
DefaultDescription: "Ubuntu 24.04 AMD64+ARM64 base image with buildpacks for Go, Java, Node.js, PHP, Python, Ruby & Scala.",
Suggested: true,
Trusted: true,
},
{
Vendor: "Heroku",
Image: "heroku/builder:22",
DefaultDescription: "Ubuntu 22.04 AMD64 base image with buildpacks for Go, Java, Node.js, PHP, Python, Ruby & Scala.",
Suggested: false,
Trusted: true,
},
{
Vendor: "Heroku",
Image: "heroku/builder:20",
DefaultDescription: "Heroku-20 (Ubuntu 20.04) base image with buildpacks for Go, Java, Node.js, PHP, Python, Ruby & Scala",
DefaultDescription: "Ubuntu 20.04 AMD64 base image with buildpacks for Go, Java, Node.js, PHP, Python, Ruby & Scala.",
Suggested: false,
Trusted: true,
},
Expand Down
4 changes: 2 additions & 2 deletions internal/commands/build_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -121,9 +121,9 @@ func testBuildCommand(t *testing.T, when spec.G, it spec.S) {
Return(nil)

logger.WantVerbose(true)
command.SetArgs([]string{"image", "--builder", "heroku/builder:22"})
command.SetArgs([]string{"image", "--builder", "heroku/builder:24"})
h.AssertNil(t, command.Execute())
h.AssertContains(t, outBuf.String(), "Builder 'heroku/builder:22' is trusted")
h.AssertContains(t, outBuf.String(), "Builder 'heroku/builder:24' is trusted")
})
})
})
Expand Down
2 changes: 1 addition & 1 deletion internal/commands/builder_inspect_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -254,7 +254,7 @@ func testBuilderInspectCommand(t *testing.T, when spec.G, it spec.S) {

assert.Matches(outBuf.String(), regexp.MustCompile(`Paketo Buildpacks:\s+'paketobuildpacks/builder-jammy-base'`))
assert.Matches(outBuf.String(), regexp.MustCompile(`Paketo Buildpacks:\s+'paketobuildpacks/builder-jammy-full'`))
assert.Matches(outBuf.String(), regexp.MustCompile(`Heroku:\s+'heroku/builder:22'`))
assert.Matches(outBuf.String(), regexp.MustCompile(`Heroku:\s+'heroku/builder:24'`))
})
})

Expand Down
4 changes: 4 additions & 0 deletions internal/commands/config_trusted_builder_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ func testTrustedBuilderCommand(t *testing.T, when spec.G, it spec.S) {
"gcr.io/buildpacks/builder:v1",
"heroku/builder:20",
"heroku/builder:22",
"heroku/builder:24",
"paketobuildpacks/builder-jammy-base",
"paketobuildpacks/builder-jammy-full",
"paketobuildpacks/builder-jammy-tiny",
Expand All @@ -73,6 +74,7 @@ func testTrustedBuilderCommand(t *testing.T, when spec.G, it spec.S) {
"gcr.io/buildpacks/builder:v1",
"heroku/builder:20",
"heroku/builder:22",
"heroku/builder:24",
"paketobuildpacks/builder-jammy-base",
"paketobuildpacks/builder-jammy-full",
"paketobuildpacks/builder-jammy-tiny",
Expand All @@ -94,6 +96,7 @@ func testTrustedBuilderCommand(t *testing.T, when spec.G, it spec.S) {
"gcr.io/buildpacks/builder:v1",
"heroku/builder:20",
"heroku/builder:22",
"heroku/builder:24",
"paketobuildpacks/builder-jammy-base",
"paketobuildpacks/builder-jammy-full",
"paketobuildpacks/builder-jammy-tiny",
Expand All @@ -111,6 +114,7 @@ func testTrustedBuilderCommand(t *testing.T, when spec.G, it spec.S) {
builderName,
"heroku/builder:20",
"heroku/builder:22",
"heroku/builder:24",
"paketobuildpacks/builder-jammy-base",
"paketobuildpacks/builder-jammy-full",
"paketobuildpacks/builder-jammy-tiny",
Expand Down
2 changes: 1 addition & 1 deletion internal/commands/inspect_builder_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ func testInspectBuilderCommand(t *testing.T, when spec.G, it spec.S) {

assert.Matches(outBuf.String(), regexp.MustCompile(`Paketo Buildpacks:\s+'paketobuildpacks/builder-jammy-base'`))
assert.Matches(outBuf.String(), regexp.MustCompile(`Paketo Buildpacks:\s+'paketobuildpacks/builder-jammy-full'`))
assert.Matches(outBuf.String(), regexp.MustCompile(`Heroku:\s+'heroku/builder:22'`))
assert.Matches(outBuf.String(), regexp.MustCompile(`Heroku:\s+'heroku/builder:24'`))
})
})

Expand Down
2 changes: 2 additions & 0 deletions internal/commands/list_trusted_builders_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ func testListTrustedBuildersCommand(t *testing.T, when spec.G, it spec.S) {
"gcr.io/buildpacks/builder:v1",
"heroku/builder:20",
"heroku/builder:22",
"heroku/builder:24",
"paketobuildpacks/builder-jammy-base",
"paketobuildpacks/builder-jammy-full",
"paketobuildpacks/builder-jammy-tiny",
Expand All @@ -89,6 +90,7 @@ func testListTrustedBuildersCommand(t *testing.T, when spec.G, it spec.S) {
builderName,
"heroku/builder:20",
"heroku/builder:22",
"heroku/builder:24",
"paketobuildpacks/builder-jammy-base",
"paketobuildpacks/builder-jammy-full",
"paketobuildpacks/builder-jammy-tiny",
Expand Down

0 comments on commit 6c4f1d9

Please sign in to comment.