juju bootstrap with --config cloudinit-userdata fails with error

As stated in the official documents Juju | Command 'bootstrap' --config cloudinit-userdata is a valid option when bootstrapping a controller, however trying to do so, results in this:

juju bootstrap cloudinit-userdata=cloudinit-userdata.yaml

ERROR cloudinit-userdata: must be valid YAML: yaml: unmarshal errors:
  line 1: cannot unmarshal !!str `cloudin...` into map[string]interface {}

File cloudinit-userdata.yaml contains:

cloudinit-userdata: |
    postruncmd:
        - curl -fsSL https://tailscale.com/install.sh | sh

For anyone interested, how it works is:

--config ./cloudinit-userdata.yaml

rather than:

--config cloudinit-userdata=cloudinit-userdata.yaml

Additional detail about cloudinit-userdata model config can be found here: