Set SLAVE=yes in ifcfg files when MASTER is set

- Fixes: #1980

Signed-off-by: Jonathon Anderson <janderson@ciq.com>
This commit is contained in:
Jonathon Anderson
2025-09-03 06:21:29 -06:00
parent 7a6a1ad441
commit 458e23d0ae
3 changed files with 4 additions and 0 deletions

View File

@@ -36,6 +36,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
### Changed ### Changed
### Fixed ### Fixed
- Set `SLAVE=yes` in ifcfg files when `MASTER` is set. #1980
## v4.6.3, 2025-08-01 ## v4.6.3, 2025-08-01

View File

@@ -282,6 +282,7 @@ writeFile: true
Filename: ifcfg-en1.conf Filename: ifcfg-en1.conf
# This file is autogenerated by warewulf # This file is autogenerated by warewulf
TYPE=Ethernet TYPE=Ethernet
SLAVE=yes
MASTER=bond0 MASTER=bond0
DEVICE=en1 DEVICE=en1
NAME=en1 NAME=en1
@@ -298,6 +299,7 @@ writeFile: true
Filename: ifcfg-en2.conf Filename: ifcfg-en2.conf
# This file is autogenerated by warewulf # This file is autogenerated by warewulf
TYPE=Ethernet TYPE=Ethernet
SLAVE=yes
MASTER=bond0 MASTER=bond0
DEVICE=en2 DEVICE=en2
NAME=en2 NAME=en2

View File

@@ -7,6 +7,7 @@ VLAN=yes
TYPE={{ default "Ethernet" $netdev.Type }} TYPE={{ default "Ethernet" $netdev.Type }}
{{- end }} {{- end }}
{{- if $netdev.Tags.master }} {{- if $netdev.Tags.master }}
SLAVE=yes
MASTER={{ $netdev.Tags.master }} MASTER={{ $netdev.Tags.master }}
{{- end }} {{- end }}
{{- if $netdev.Device }} {{- if $netdev.Device }}