name: "machine-config-daemon-host.service"
enabled: false
contents: |
  [Unit]
  Description=Machine Config Daemon Initial
  # This only applies to ostree (MCD) systems;
  # see also https://github.com/openshift/machine-config-operator/issues/1046
  ConditionPathExists=/run/ostree-booted
  ConditionPathExists=/etc/pivot/image-pullspec
  # If pivot exists, defer to it.  Note similar code in update.go
  ConditionPathExists=!/usr/lib/systemd/system/pivot.service
  After=ignition-firstboot-complete.service
  Before=kubelet.service

  [Service]
  # Need oneshot to delay kubelet
  Type=oneshot
  # TODO add --from-etc-pullspec after ratcheting
  ExecStart=/usr/libexec/machine-config-daemon pivot

  [Install]
  WantedBy=multi-user.target
