Skip to content

Suggestion: use limactl list --json #4

@AkihiroSuda

Description

@AkihiroSuda

First, thanks a lot for working on this

for limavm in $(limactl list | grep -v 'NAME STATUS SSH ARCH DIR' | awk '{ print $1 }')

The grep above doesn't seem robust, and will probably break soon with a future version of Lima.
I'd suggest using limactl list --json and use jq for parsing JSON.

$ limactl list --json  | jq .
{
  "name": "default",
  "status": "Running",
  "dir": "/Users/suda/.lima/default",
  "arch": "x86_64",
  "sshLocalPort": 60022,
  "hostAgentPID": 1968,
  "qemuPID": 1972
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions