7 lines
160 B
Bash
7 lines
160 B
Bash
|
|
#!/bin/sh
|
||
|
|
|
||
|
|
multipass list --format=json |jq '{
|
||
|
|
_meta: {hostvars: [.list[] | {(.name): {ansible_host: .ipv4[-1]}}] | add},
|
||
|
|
linux: {hosts: [.list[].name]}
|
||
|
|
}'
|