{"record":{"id":"64e5883d121b5721","repo":"abiosoft/colima","slug":"s-is-not-running-64e588","errorCode":null,"errorMessage":"%s is not running","messagePattern":"(.+?) is not running","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"model/runner.go","lineNumber":87,"sourceCode":"}\n\n// GetRunner returns the appropriate Runner based on type.\nfunc GetRunner(runnerType RunnerType) (Runner, error) {\n\tswitch runnerType {\n\tcase RunnerDocker:\n\t\treturn &dockerRunner{}, nil\n\tcase RunnerRamalama:\n\t\treturn &ramalamaRunner{}, nil\n\tdefault:\n\t\treturn nil, fmt.Errorf(\"unknown runner type: %s (valid options: docker, ramalama)\", runnerType)\n\t}\n}\n\n// validateCommonPrerequisites checks prerequisites common to all runners.\nfunc validateCommonPrerequisites(a app.App) error {\n\t// VM must be running\n\tif !a.Active() {\n\t\treturn fmt.Errorf(\"%s is not running\", config.CurrentProfile().DisplayName)\n\t}\n\n\t// check runtime is docker\n\tr, err := a.Runtime()\n\tif err != nil {\n\t\treturn err\n\t}\n\tif r != docker.Name {\n\t\treturn fmt.Errorf(\"'colima model' requires docker runtime, current runtime is %s\\n\"+\n\t\t\t\"Start colima with: colima start --runtime docker --vm-type krunkit\", r)\n\t}\n\n\t// check VM type is krunkit (required for GPU access)\n\tconf, err := configmanager.LoadInstance()\n\tif err != nil {\n\t\treturn fmt.Errorf(\"error loading instance config: %w\", err)\n\t}\n\tif conf.VMType != limaconfig.Krunkit {","sourceCodeStart":69,"sourceCodeEnd":105,"githubUrl":"https://github.com/abiosoft/colima/blob/c3a5f9184d83a197184f897a9f07eb3c01b3bc88/model/runner.go#L69-L105","documentation":"validateCommonPrerequisites runs before every colima model operation and first asserts the VM is up; a.Active() returned false and the current profile's DisplayName is interpolated into the message. No model-layer operation can proceed while the VM is stopped.","triggerScenarios":"Executing any colima model subcommand (list/run/pull/status) while the VM is stopped, still starting, or suspended.","commonSituations":"Machines after reboot without colima autostart; CI steps that forget colima start; commands issued seconds after start before the VM reports active.","solutions":["Start the VM and retry: colima start (model commands additionally need --runtime docker --vm-type krunkit)","Check state first: colima status — wait until it reports running","If colima start itself fails, fix that first; the model layer cannot bring the VM up"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"// caller-side pre-check mirroring the first prerequisite\nif !a.Active() {\n\tif err := a.Start(false); err != nil {\n\t\treturn fmt.Errorf(\"cannot start VM: %w\", err)\n\t}\n}\nreturn runner.ValidatePrerequisites(a)","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Script colima start (or a state check) before any colima model command","Poll colima status until running rather than sleeping a fixed time after start"],"tags":["vm","lifecycle","cli","go"],"backgroundTag":null,"analyzedSha":"c3a5f9184d83a197184f897a9f07eb3c01b3bc88","analyzedAt":"2026-08-15T18:58:08.334Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}