abiosoft/colima · error
mount path with spaces is not supported by the underlying Li
Error message
mount path with spaces is not supported by the underlying Lima runtime: %q
What it means
validateMounts rejects any mounts entry whose location or mountPoint contains a space (strings.Contains(p, " ")). The underlying Lima runtime fails silently on spaced paths (referenced issue abiosoft/colima#1471), so colima validates up front and names the offending path in the error.
Source
Thrown at config/configmanager/configmanager.go:157
return fmt.Errorf("gateway %q is not IPv4", gateway)
}
// Check last octet
if ip4[3] != 2 {
return fmt.Errorf("the last octet of gateway %q is not 2", gateway)
}
return nil
}
// validateMounts ensures mount paths do not contain spaces, which are not
// supported by the underlying Lima runtime and otherwise fail silently.
// See https://github.com/abiosoft/colima/issues/1471.
func validateMounts(mounts []config.Mount) error {
for _, m := range mounts {
for _, p := range []string{m.Location, m.MountPoint} {
if strings.Contains(p, " ") {
return fmt.Errorf("mount path with spaces is not supported by the underlying Lima runtime: %q", p)
}
}
}
return nil
}
View on GitHub (pinned to c3a5f9184d)
Solutions
- Mount a space-free parent directory and access the spaced subfolder from inside it
- Create a symlink without spaces (ln -s "$HOME/My Projects" "$HOME/my-projects") and mount the symlink path
- Rename the directory if feasible, or drop the mount if it is optional
Example fix
# before mounts: - location: ~/My Projects # after (symlink workaround) ln -s "$HOME/My Projects" "$HOME/my-projects" mounts: - location: ~/my-projects
Defensive patterns
Strategy: validation
Validate before calling
for _, m := range c.Mounts {
for _, p := range []string{m.Location, m.MountPoint} {
if strings.Contains(p, " ") {
// create a space-free symlink or mount a parent dir without spaces
}
}
} Try / catch
if err := configmanager.ValidateConfig(c); err != nil {
if strings.Contains(err.Error(), "spaces is not supported") {
// the offending path is printed; symlink it to a space-free name
}
} Prevention
- Keep project directories mountable: avoid spaces in paths under version control
- Use symlinks for legacy spaced directory names
- Prefer mounting the home directory or a workspace root and referencing subpaths inside the VM
When it happens
Trigger: A mounts entry in colima.yaml such as location: ~/My Projects or mountPoint: /home/ubuntu.linux.coder/My Files. Trailing and embedded spaces both trigger it because the check is a substring scan.
Common situations: Mounting project folders like 'Google Drive', 'VirtualBox VMs', or 'My Documents'; macOS default folder names containing spaces; configs ported from docker-compose volume syntax where spaces were tolerated.
Related errors
- overlapping mounts not supported: %w
- invalid mountType: '%s'
- relative paths not supported for mount '%s'
- error persisting runtime settings: %w
- error persisting kubernetes settings: %w
AI-assisted analysis of abiosoft/colima@c3a5f9184d (2026-08-15).
Data as JSON: /api/errors/92da004b1bdf739b.
Report an issue: GitHub.