Mark Goddard 7173a9f731 ntp: Fix service mask when service doesn't exist
The ntp role attempts to mask NTP services that may conflict with
chrony. Currently we are seeing the following failure:

    TASK ntp : Mask alternative NTP clients to prevent conflicts
    Could not find the requested service systemd-timesyncd.service: host

The service_facts module shows that the service is not found:

    "systemd-timesyncd.service": {
        "name": "systemd-timesyncd.service",
        "source": "systemd",
        "state": "stopped",
        "status": "not-found"
    },

According to the Internet, this can happen if there are After/Before
dependencies in one service on another that does not exist.

This change fixes the handling of these not-found services to avoid the
error.

Story: 2009821
Task: 44401

Depends-On: https://review.opendev.org/c/openstack/kayobe/+/827404

Change-Id: I4b8a42704f2b0a145ee9dec433d91df67628cd9d
2022-02-02 16:46:03 +00:00
..
2021-10-04 12:40:54 +01:00
2020-07-24 09:11:45 +01:00
2019-10-25 17:08:56 +01:00
2017-05-29 16:52:17 +01:00
2021-10-06 14:30:58 +02:00
2020-12-14 14:48:05 +00:00
2021-10-04 12:40:54 +01:00
2021-10-04 12:40:54 +01:00
2021-10-04 12:40:54 +01:00
2021-10-04 12:40:54 +01:00
2021-10-04 12:40:54 +01:00
2021-05-11 20:41:17 +00:00
2021-10-04 12:40:54 +01:00
2021-10-04 12:40:54 +01:00