Dmitriy Rabotyagov fc954761d1 Do not try to configure resolved when it's not available
While having `systemd_resolved_available` variable which controls if
systemd-resolved will be restarted in handlers.

However, way better approach is to prevent resolved from being
configured at the first place, which will result in skipping handler
execution on it's own.

With that we add control over systemd-resolved package installed with
the same `systemd_resolved_available` variable, so that package
installation is omited when variable is set to False.

Change-Id: Ib2471850386bb125a92c02fb21874e100a03459d
2025-01-07 14:51:25 +00:00

30 lines
958 B
YAML

---
# Copyright 2020, VEXXHOST Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
_systemd_networkd_distro_packages:
- systemd-networkd
- "{{ systemd_resolved_available | ternary('systemd-resolved', '') }}"
_systemd_resolved_available: false
_systemd_networkd_update_initramfs: "dracut -f"
systemd_networkd_enablerepo: epel
systemd_networkd_package_repos_keys:
- name: epel-8
key: /etc/pki/rpm-gpg/RPM-GPG-KEY-EPEL-8
keyfile: gpg/2F86D6A1