Skip to content

Commit

Permalink
fix issue 211: DNS Search Domain not applying
Browse files Browse the repository at this point in the history
Added the DnsSearchStr to the template to include the dns search domain in the generated config file
  • Loading branch information
mtahernia authored Mar 11, 2024
1 parent 1b4b5ff commit 44429a2
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions internal/app/configfile/tpl_files/wg_peer.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Address = {{ CidrsToString .Peer.Interface.Addresses }}

# Misc. settings (optional)
{{- if .Peer.Interface.DnsStr.GetValue}}
DNS = {{ .Peer.Interface.DnsStr.GetValue }}
DNS = {{ .Peer.Interface.DnsStr.GetValue }} {{- if .Peer.Interface.DnsSearchStr.GetValue}}, {{ .Peer.Interface.DnsSearchStr.GetValue }} {{- end}}
{{- end}}
{{- if ne .Peer.Interface.Mtu.GetValue 0}}
MTU = {{ .Peer.Interface.Mtu.GetValue }}
Expand Down Expand Up @@ -62,4 +62,4 @@ PresharedKey = {{ .Peer.PresharedKey }}
{{- end}}
{{- if and (ne .Peer.PersistentKeepalive.GetValue 0) (eq .Peer.Interface.Type "client")}}
PersistentKeepalive = {{ .Peer.PersistentKeepalive.GetValue }}
{{- end}}
{{- end}}

0 comments on commit 44429a2

Please sign in to comment.