It appears we have the following *ordering* relationship between systemd-resolved.service, cloud-init.service, network.target, and network-online.target:
network-online.target |---network.target ....|---systemd-resolved.service |---cloud-init.service
See attached graph for more details. This is consistent with the timeline shown in comment #13.
Since cloud-init.service apparently requires DNS, I would simply try to add `After=systemd-resolved.service` to `cloud-init.service`.
It appears we have the following *ordering* relationship between systemd- resolved. service, cloud-init.service, network.target, and network- online. target:
network- online. target -systemd- resolved. service init.service
|---network.target
....|--
|---cloud-
See attached graph for more details. This is consistent with the timeline shown in comment #13.
Since cloud-init.service apparently requires DNS, I would simply try to add `After= systemd- resolved. service` to `cloud- init.service` .