Build containers. Skip the daemon.
Quick Start | Features | CLI Reference | Go Library
Gib is a lightweight, daemonless container image builder and a drop-in replacement for Jib CLI. One static binary, no JVM. Your existing jib.yaml files just work.
- Drop-in Jib replacement — 100% compatible with
jib.yamlbuild files - No runtime dependencies — builds container images directly, no daemon or JVM needed
- Go library — use programmatically in your Go applications
- Powered by go-containerregistry — battle-tested container image library
- Modern CLI — powered by Fang
With mise-gib (recommended):
mise plugin install gib https://github.com/jbadeau/mise-gib.git
mise install gib@latest
mise use gib@latestWith go install:
go install github.com/jbadeau/gib/cmd/gib@latestgib build --target=my-registry.example.com/my-app:latestgib build --target=tar://my-image.tarapiVersion: jib/v1alpha1
kind: BuildFile
from:
image: ubuntu
entrypoint: ["/app/run.sh"]
layers:
entries:
- name: app
files:
- src: .
dest: /appgib build --target <image> [options]
| Option | Description |
|---|---|
-t, --target |
(required) Target image reference or tar://<path> |
-b, --build-file |
Build file path (default: jib.yaml) |
-c, --context |
Build context directory (default: .) |
-p, --parameter |
Template parameter key=value (repeatable) |
--from |
Override base image |
--image-format |
Docker or OCI (default: Docker) |
--additional-tags |
Extra tags for registry targets |
--credential-helper |
Docker credential helper suffix |
--username / --password |
Registry credentials |
Run gib build --help for the full list of options.
Use Gib programmatically to build container images in your Go applications:
builder := gib.From("ubuntu:22.04").
SetEntrypoint("sh", "run.sh").
SetUser("appuser").
SetWorkingDirectory("/app")
result, err := builder.Containerize(
context.Background(),
gib.ToRegistry("my-registry.example.com/app:v1"),
)Or build from an existing jib.yaml:
spec, _ := buildfile.Parse("jib.yaml", nil)
builder, _ := buildfile.Convert(spec, ".", nil)
result, _ := builder.Containerize(ctx, gib.ToTar("image.tar"))