MCPcopy Index your code
hub / github.com/coder/coder / WorkspaceBuild

Function WorkspaceBuild

cli/cliui/provisionerjob.go:21–31  ·  view source on GitHub ↗
(ctx context.Context, writer io.Writer, client *codersdk.Client, build uuid.UUID)

Source from the content-addressed store, hash-verified

19)
20
21func WorkspaceBuild(ctx context.Context, writer io.Writer, client *codersdk.Client, build uuid.UUID) error {
22 return ProvisionerJob(ctx, writer, ProvisionerJobOptions{
23 Fetch: func() (codersdk.ProvisionerJob, error) {
24 build, err := client.WorkspaceBuild(ctx, build)
25 return build.Job, err
26 },
27 Logs: func() (<-chan codersdk.ProvisionerJobLog, io.Closer, error) {
28 return client.WorkspaceBuildLogsAfter(ctx, build, 0)
29 },
30 })
31}
32
33type ProvisionerJobOptions struct {
34 Fetch func() (codersdk.ProvisionerJob, error)

Callers 13

findWorkspaceAndAgentFunction · 0.92
stopMethod · 0.92
startMethod · 0.92
restartMethod · 0.92
portForwardMethod · 0.92
waitForTaskIdleFunction · 0.92
taskPauseMethod · 0.92
updateMethod · 0.92
deleteWorkspaceMethod · 0.92
GetWorkspaceAndAgentFunction · 0.92
taskResumeMethod · 0.92
statePushMethod · 0.92

Calls 3

WorkspaceBuildMethod · 0.80
ProvisionerJobFunction · 0.70

Tested by

no test coverage detected