Skip to content

Commit a1a1bf5

Browse files
authored
Merge pull request #342 from bastelfreak/cleanupdatatypes
cleanup types in openvpn::client_specific_config
2 parents 16fa257 + e20a34c commit a1a1bf5

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

manifests/client_specific_config.pp

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -23,14 +23,14 @@
2323
# dhcp_options => ['DNS 8.8.8.8']
2424
# }
2525
define openvpn::client_specific_config (
26-
String $server,
27-
Enum[present, absent] $ensure = present,
28-
Array[String] $iroute = [],
29-
Array[String] $iroute_ipv6 = [],
30-
Array[String] $route = [],
31-
Variant[Boolean, String] $ifconfig = false,
26+
String[1] $server,
27+
Enum['present', 'absent'] $ensure = present,
28+
Array[String[1]] $iroute = [],
29+
Array[String[1]] $iroute_ipv6 = [],
30+
Array[String[1]] $route = [],
31+
Optional[String[1]] $ifconfig = undef,
3232
Optional[String[1]] $ifconfig_ipv6 = undef,
33-
Array[String] $dhcp_options = [],
33+
Array[String[1]] $dhcp_options = [],
3434
Boolean $redirect_gateway = false,
3535
Boolean $manage_client_configs = true,
3636
) {

templates/client_specific_config.erb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ iroute <%= iroute %>
44
<% @iroute_ipv6.each do |iroute_ipv6| -%>
55
iroute-ipv6 <%= iroute_ipv6 %>
66
<% end -%>
7-
<% if ifconfig = @ifconfig -%>
8-
ifconfig-push <%= ifconfig %>
7+
<% if @ifconfig -%>
8+
ifconfig-push <%= @ifconfig %>
99
<% end -%>
1010
<% if @ifconfig_ipv6 -%>
1111
ifconfig-ipv6-push <%= @ifconfig_ipv6 %>

0 commit comments

Comments
 (0)