MCPcopy Index your code
hub / github.com/GoogleCloudPlatform/buildpacks

github.com/GoogleCloudPlatform/buildpacks @main

Chat with this repo
repository ↗ · DeepWiki ↗ · + Follow
3,911 symbols 13,474 edges 1,052 files 1,132 documented · 29%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Google Cloud's buildpacks

This repository contains a set of builders and buildpacks designed to run on Google Cloud's container platforms: Cloud Run, GKE, Anthos, and Compute Engine running Container-Optimized OS. They are also used as the build system for App Engine and Cloud Functions. They are 100% compatible with Cloud Native Buildpacks.

To start using Google Cloud's buildpacks

Additional tooling

The Google Cloud's buildpacks project provides builder images suitable for use with pack, kpack, tekton, skaffold, and other tools that support the Buildpacks v3 specification.

Additional Configurations

Google Cloud's buildpacks can be configured in a few ways:

App Engine and Cloud Function Builders and Buildpacks

These builders create container images designed to run on Google Cloud's App Engine and Functions services. Most of the buildpacks are identical to those in the general builder.

Compared to the general builder, there are two primary differences. First, there are additional buildpacks which add transformations specific to each service. Second, in order to optimize execution speed, each language has a separate builder.

As an example, in order to build a Docker container image for Google App Engine Java17 runtime you can use:

pack build <app-name>  --builder gcr.io/serverless-runtimes/google-22-full/builder/java

If you rely on a custom App Engine entrypoint in your app.yaml, you can use:

pack build <app-name>  --builder gcr.io/serverless-runtimes/google-22-full/builder/java  --env GOOGLE_ENTRYPOINT="your entry point command"

The application container image can then be executed locally:

docker run --rm -p 8080:8080 <app-name>

Locally, your application might depend on App Engine environment variables that would need to be set in the local environment.

Learn more about Cloud Native Buildpacks

This project implements the Cloud Native Buildpacks specification. To read more, see Cloud Native Buildpacks project documentation.

For those new to buildpacks, these concepts are good starting points:

  • Builder A container image that contains buildpacks and detection order in which builds are executed.
  • Buildpack An executable that "inspects your app source code and formulates a plan to build and run your application".
  • Buildpack Group Several buildpacks which together provide support for a specific language or framework.
  • Run Image The container image that serves as the base for the built application.

Support

Google Cloud's buildpacks are only officially supported when used with Google Cloud products. Customers of Google Cloud can use standard support channels for help using buildpacks with Google Cloud Products.

Security

For information on reporting security vulnerabilities, see SECURITY.md.

Get involved with the community

We welcome contributions! Here's how you can contribute:

License

See LICENSE.

Extension points exported contracts — how you extend this code

UVDependenciesInstaller (Interface)
UVDependenciesInstaller is an interface for installing python dependencies using uv. [7 implementers]
pkg/python/python.go
ComposerInstaller (Interface)
ComposerInstaller is an interface for installing Composer. [7 implementers]
pkg/php/php.go
GemsInstaller (Interface)
GemsInstaller is an interface for installing RubyGems. [7 implementers]
pkg/ruby/ruby.go
Exiter (Interface)
Exiter is responsible to exit the program appropriately; useful for unit tests. [3 implementers]
pkg/gcpbuildpack/exit.go
GoBuilder (Interface)
GoBuilder is an interface for building Go applications. [1 implementers]
pkg/golang/golang.go
SecretManager (Interface)
SecretManager is an interface for the Secret Manager API [1 implementers]
pkg/firebase/secrets/secrets.go
PNPMInstaller (Interface)
PNPMInstaller is an interface for installing pnpm. [1 implementers]
pkg/nodejs/pnpm.go
SkipEnvVariablesAssignment (Interface)
SkipEnvVariablesAssignment is an interface for skipping runtime environment variables assignment. [1 implementers]
pkg/dotnet/dotnet.go

Core symbols most depended-on inside this repo

Logf
called by 280
pkg/gcpbuildpack/gcpbuildpack.go
Exec
called by 181
pkg/gcpbuildpack/exec.go
FileExists
called by 173
pkg/gcpbuildpack/os.go
TempDir
called by 139
pkg/gcpbuildpack/ioutil.go
ApplicationRoot
called by 122
pkg/gcpbuildpack/gcpbuildpack.go
Setenv
called by 119
pkg/gcpbuildpack/os.go
Warnf
called by 104
pkg/gcpbuildpack/gcpbuildpack.go
New
called by 99
internal/mockprocess/mockprocess.go

Shape

Function 2,265
Method 1,151
Struct 189
Class 186
Route 60
Interface 27
TypeAlias 17
FuncType 16

Languages

Go54%
TypeScript35%
Python4%
Java3%
C#2%
Ruby1%

Modules by API surface

builders/testdata/nodejs/functions/yarn_two_pnp/.pnp.cjs667 symbols
builders/testdata/nodejs/appengine/yarn_two_pnp/.pnp.cjs657 symbols
internal/acceptance/acceptance.go65 symbols
pkg/gcpbuildpack/gcpbuildpack.go54 symbols
pkg/python/python.go45 symbols
pkg/nodejs/nodejs.go40 symbols
pkg/dotnet/dotnet.go36 symbols
pkg/runtime/install.go33 symbols
cmd/nodejs/legacy_worker/converter/worker/worker.js27 symbols
pkg/gcpbuildpack/gcpbuildpack_test.go26 symbols
cmd/nodejs/firebasebundle/lib/lib.go25 symbols
pkg/golang/golang.go24 symbols

For agents

$ claude mcp add buildpacks \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact