mirror of
https://github.com/linux-system-roles/network.git
synced 2026-01-23 02:15:17 +00:00
Defaults: Break long lines
This commit is contained in:
parent
4fb9eb3dcc
commit
85f16ddf6f
1 changed files with 19 additions and 8 deletions
|
|
@ -4,8 +4,11 @@ network_connections: []
|
|||
|
||||
# Use initscripts for RHEL/CentOS < 7, nm otherwise
|
||||
network_provider_os_default: "{{
|
||||
'initscripts' if ansible_distribution in ['RedHat', 'CentOS', 'OracleLinux'] and
|
||||
ansible_distribution_major_version is version('7', '<')
|
||||
'initscripts' if ansible_distribution in [
|
||||
'RedHat',
|
||||
'CentOS',
|
||||
'OracleLinux'
|
||||
] and ansible_distribution_major_version is version('7', '<')
|
||||
else 'nm' }}"
|
||||
# If NetworkManager.service is running, assume that 'nm' is currently in-use,
|
||||
# otherwise initscripts
|
||||
|
|
@ -26,21 +29,29 @@ network_service_name_default_nm: NetworkManager
|
|||
network_packages_default_nm:
|
||||
- ethtool
|
||||
- NetworkManager
|
||||
- "python{{ ansible_python['version']['major'] | replace('2', '') }}-gobject-base"
|
||||
- "python{{ ansible_python['version']['major'] | replace('2', '')
|
||||
}}-gobject-base"
|
||||
|
||||
network_service_name_default_initscripts: network
|
||||
|
||||
# initscripts requires bridge-utils to manage bridges, install it when the
|
||||
# 'bridge' type is used in network_connections
|
||||
_network_packages_default_initscripts_bridge: ["{% if ['bridge'] in network_connections|json_query('[*][type]') and
|
||||
_network_packages_default_initscripts_bridge: ["{%
|
||||
if ['bridge'] in network_connections|json_query('[*][type]') and
|
||||
(
|
||||
(ansible_distribution in ['RedHat', 'CentOS', 'OracleLinux'] and ansible_distribution_major_version is version('7', '<=')) or
|
||||
(ansible_distribution == 'Fedora' and ansible_distribution_major_version is version('28', '<='))
|
||||
(ansible_distribution in ['RedHat', 'CentOS', 'OracleLinux'] and
|
||||
ansible_distribution_major_version is version('7', '<='))
|
||||
or
|
||||
(ansible_distribution == 'Fedora' and
|
||||
ansible_distribution_major_version is version('28', '<='))
|
||||
)
|
||||
%}bridge-utils{% endif %}"]
|
||||
_network_packages_default_initscripts_network_scripts: ["{%
|
||||
if (ansible_distribution in ['RedHat', 'CentOS', 'OracleLinux'] and ansible_distribution_major_version is version('7', '<=')) or
|
||||
(ansible_distribution == 'Fedora' and ansible_distribution_major_version is version('28', '<='))
|
||||
if (ansible_distribution in ['RedHat', 'CentOS', 'OracleLinux'] and
|
||||
ansible_distribution_major_version is version('7', '<='))
|
||||
or
|
||||
(ansible_distribution == 'Fedora' and
|
||||
ansible_distribution_major_version is version('28', '<='))
|
||||
%}initscripts{% else %}network-scripts{% endif %}"]
|
||||
# convert _network_packages_default_initscripts_bridge to an empty list if it
|
||||
# contains only the empty string and add it to the default package list
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue