oxidecomputer / omicron

Omicron: Oxide control plane

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Tools] create_virtual_hardware.sh will use comments when searching for vdevs

leftwo opened this issue · comments

The ensure_vdev bash function in tools/virtual_hardware.sh uses this logic to
build the list of VDEVS:

        readarray -t VDEVS < <( \
                grep "\"$VDEV_TYPE" "$OMICRON_TOP/smf/sled-agent/non-gimlet/config.toml" | \
                sed 's/[ ",]//g' \
            )

This will match on lines that begin with #, which an unsuspecting user (me) might have
assumed would be skipped when the config file is read.