weaveworks / ignite

Ignite a Firecracker microVM
https://ignite.readthedocs.org
Apache License 2.0
3.49k stars 223 forks source link

Malformed syntax & outdated/invalid `jq` argument in kubeadm image README #740

Closed EmeraldShift closed 3 years ago

EmeraldShift commented 3 years ago

images/kubeadm/README.md fetches the IP address of the master-0 VM with the following line:

export MASTER_IP=$($ignite inspect vm master-0 | jq -r ".status.ipAddresses[0]")

This seems to be problematic, since there's an extra $ before ignite, which (unless set) evaluates to an empty string, causing the shell to run inspect ..., to no avail.

Additionally, the JSON path .status.ipAddresses[0] seems either invalid or outdated, as the correct path appears to be .status.network.ipAddresses[0] as of the time of writing.

darkowlzz commented 3 years ago

Hi, thanks for opening an issue for this. We changed the location of ipAddresses recently in v0.8.0 and weren't aware of it being used here. .status.network.ipAddresses[0] should be the new path. $ignite might have been a local variable on the machine the doc was tested and written on. We should fix it. If possible, a patch fixing these would be of great help. 🙂