Skip to content

Commit

Permalink
fix: Allow network to restart when wireless or team connection is spe…
Browse files Browse the repository at this point in the history
…cified

When wireless or team connection is specified, we should allow network
to restart by default regardless of whether network packages are
changed on the managed host.

The commit will fix the situation that users forget to explicitly
specify `network_allow_restart: true` when specifying wireless or team
connection.

Signed-off-by: Wen Liang <liangwen12year@gmail.com>
  • Loading branch information
liangwen12year committed Feb 19, 2024
1 parent 4b12e15 commit 876ed42
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
---
network_connections: []

network_allow_restart: false

# Ansible distribution identifiers that the role treats like RHEL
__network_rh_distros:
- AlmaLinux
Expand Down Expand Up @@ -50,6 +48,11 @@ __network_packages_default_team: ["{%
if __network_team_connections_defined
%}NetworkManager-team{% endif %}"]

# if wireless or team connection is specified, NetworkManager should be
# allowed to restart by default
network_allow_restart: "{{ __network_wireless_connections_defined or
__network_team_connections_defined }}"

# wpa_supplicant is required if any 802.1x or wireless connections are defined
__network_wpa_supplicant_required: "{{
__network_ieee802_1x_connections_defined or
Expand Down

0 comments on commit 876ed42

Please sign in to comment.