MCPcopy Index your code
hub / github.com/ddev/ddev / Wait

Method Wait

pkg/ddevapp/ddevapp.go:3034–3049  ·  view source on GitHub ↗

Wait ensures that the app service containers are healthy.

(requiredContainers []string)

Source from the content-addressed store, hash-verified

3032
3033// Wait ensures that the app service containers are healthy.
3034func (app *DdevApp) Wait(requiredContainers []string) error {
3035 for _, containerType := range requiredContainers {
3036 labels := map[string]string{
3037 "com.ddev.site-name": app.GetName(),
3038 "com.docker.compose.service": containerType,
3039 "com.docker.compose.oneoff": "False",
3040 }
3041 waitTime := app.GetMaxContainerWaitTime()
3042 logOutput, err := dockerutil.ContainerWait(waitTime, labels)
3043 if err != nil {
3044 return fmt.Errorf("%s container failed: log=%s, err=%v", containerType, logOutput, err)
3045 }
3046 }
3047
3048 return nil
3049}
3050
3051// WaitByLabels waits for containers found by list of labels to be
3052// ready

Callers 15

StartMethod · 0.95
StartOptionalProfilesMethod · 0.95
SnapshotMethod · 0.95
drupalPostStartActionFunction · 0.80
startLogStreamCmdFunction · 0.80
startOperationStreamCmdFunction · 0.80
copyToClipboardFunction · 0.80
RunInteractiveCommandFunction · 0.80
ComposeCmdFunction · 0.80
TestCaptureOutputToFileFunction · 0.80

Calls 4

GetNameMethod · 0.95
ContainerWaitFunction · 0.92
ErrorfMethod · 0.80

Tested by 6

TestCaptureOutputToFileFunction · 0.64
startNCListenerFunction · 0.64
TestShareCmdNgrokFunction · 0.64
TestShareCmdCloudflaredFunction · 0.64