Daemon: builds

cua.daemon.v1 builds: the messages of SpaceService.BuildSpace, ListBuilds and DeleteBuild.

Building an image from a Dockerfile or steps into pinned checkpoints, its progress, result and listing.

Source: libs/cua/proto/cua/daemon/v1/builds.proto.

Types in cua/daemon/v1/builds.proto#

BuildSpaceRequest#

Request for SpaceService.BuildSpace: give a Dockerfile, or a base and steps.

Field#TypeDescription
dockerfile1stringDockerfile text.
context_dir2stringThe build context: the directory COPY sources are relative to, on the daemon's machine.
base3stringThe base image for a build of steps alone.
steps_json4stringJSON array of build steps ({"op":"run","command":"make"}, copy, env, workdir, user, ...), after the Dockerfile's.
build_args5map of string to stringBuild arguments (ARG values).
tag6stringAlias for the result.
kind7string"vm" (default, empty), "container" or "microvm".
location8stringWhere: "local" (default, empty). A build's checkpoints stay on the machine that took them.
cpus9uint32vCPUs of the machine (0: 2).
memory_mb10uint64Memory in MiB (0: 4096).
headless11optional boolNo desktop (unset: true).
no_cache12boolBuild every layer again.
step_timeout13google.protobuf.DurationBudget for each step (default 1 hour).

BuildProgress#

What a build is doing.

Field#TypeDescription
event1string"note", "step", "output", "step_done" or "finished".
index2uint32The step (0: the base image).
total3uint32Steps after the base.
text4stringThe step as a line, a note, or an output line.
cached5bool"step": served from a cached layer. "finished": nothing ran.
seconds6double"step_done" and "finished": seconds taken.
checkpoint7string"step_done": the layer's checkpoint.

BuildStepResult#

One step of a finished build.

Field#TypeDescription
index1uint32The step (0: the base image).
text2stringThe step as a line.
cached3boolServed from a cached layer.
seconds4doubleSeconds taken (0 when cached).
checkpoint5stringThe layer's checkpoint, for a step that makes one.

BuildResult#

A finished build.

Field#TypeDescription
checkpoint1stringThe final layer's checkpoint (a fork source).
tag2stringThe tag, when asked for.
key3stringThe recipe's cache key.
cached4boolEvery layer was cached.
steps5repeated BuildStepResultOne per step, base first.
config_json6stringJSON image configuration (env, workdir, user, cmd, ...).
seconds7doubleSeconds the build took.

BuildSpaceResponse#

One message of SpaceService.BuildSpace.

Field#TypeDescription
progress1BuildProgress (oneof event)What the build is doing now.
result2BuildResult (oneof event)The result (the last message).

ListBuildsRequest#

Request for SpaceService.ListBuilds.

No fields.

BuildInfo#

A build on this machine.

Field#TypeDescription
checkpoint1stringThe final layer's checkpoint.
key2stringThe recipe's cache key.
tags3repeated stringTags naming it.
base4stringThe FROM reference.
layers5repeated stringLayers it is made of (checkpoints), base first.
created_at6stringRFC 3339 build time.
config_json7stringJSON image configuration.

ListBuildsResponse#

Response for SpaceService.ListBuilds.

Field#TypeDescription
builds1repeated BuildInfoBuilds, oldest first.

DeleteBuildRequest#

Request for SpaceService.DeleteBuild.

Field#TypeDescription
build1stringA tag, a recipe key (or its first 12 characters) or a checkpoint.

DeleteBuildResponse#

Response for SpaceService.DeleteBuild.

Field#TypeDescription
deleted1repeated stringThe layer checkpoints deleted.