Skip to content
This repository has been archived by the owner on Jul 9, 2020. It is now read-only.

Commit

Permalink
Refs #20271 - remove to_proc syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
ekohl authored and mmoll committed Aug 14, 2017
1 parent d2b82a8 commit 1135f32
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ timezone --utc <%= @host.params['time-zone'] || 'UTC' %>
<% dhcp = !@static -%>
<% end -%>

network --bootproto <%= dhcp ? 'dhcp' : "static --ip=#{@host.ip} --netmask=#{subnet.mask} --gateway=#{subnet.gateway} --nameserver=#{[subnet.dns_primary, subnet.dns_secondary].select(&:present?).join(',')}" %> --hostname <%= @host %><%= " --device=#{@host.mac}" -%>
network --bootproto <%= dhcp ? 'dhcp' : "static --ip=#{@host.ip} --netmask=#{subnet.mask} --gateway=#{subnet.gateway} --nameserver=#{[subnet.dns_primary, subnet.dns_secondary].select{ |item| item.present? }.join(',')}" %> --hostname <%= @host %><%= " --device=#{@host.mac}" -%>

# Partition table should create /boot and a volume atomicos
<% if @dynamic -%>
Expand Down
2 changes: 1 addition & 1 deletion provisioning_templates/provision/coreos_provision.erb
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ coreos:
X-Conflicts=coreos-bootstrap.service
<% if @host.params['ssh_authorized_keys'] -%>
ssh_authorized_keys:
<% @host.params['ssh_authorized_keys'].split(',').map(&:strip).each do |ssh_key| -%>
<% @host.params['ssh_authorized_keys'].split(',').map{ |item| item.strip }.each do |ssh_key| -%>
- "<%= ssh_key %>"
<% end -%>
<% else -%>
Expand Down
2 changes: 1 addition & 1 deletion provisioning_templates/provision/kickstart_default.erb
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ skipx
<% else -%>
<% dhcp = !@static -%>
<% end -%>
network --bootproto <%= dhcp ? 'dhcp' : "static --ip=#{@host.ip} --netmask=#{subnet.mask} --gateway=#{subnet.gateway} --nameserver=#{[subnet.dns_primary, subnet.dns_secondary].select(&:present?).join(',')}" %> --hostname <%= @host %><%= os_major >= 6 ? " --device=#{@host.mac}" : '' -%>
network --bootproto <%= dhcp ? 'dhcp' : "static --ip=#{@host.ip} --netmask=#{subnet.mask} --gateway=#{subnet.gateway} --nameserver=#{[subnet.dns_primary, subnet.dns_secondary].select{ |item| item.present? }.join(',')}" %> --hostname <%= @host %><%= os_major >= 6 ? " --device=#{@host.mac}" : '' -%>

rootpw --iscrypted <%= root_pass %>
<% if @host.param_true?('disable-firewall') -%>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ skipx
<% else -%>
<% dhcp = !@static -%>
<% end -%>
network --bootproto <%= dhcp ? 'dhcp' : "static --ip=#{@host.ip} --netmask=#{subnet.mask} --gateway=#{subnet.gateway} --nameserver=#{[subnet.dns_primary, subnet.dns_secondary].select(&:present?).join(',')}" %> --hostname <%= @host %><%= os_major >= 6 ? " --device=#{@host.mac}" : '' -%>
network --bootproto <%= dhcp ? 'dhcp' : "static --ip=#{@host.ip} --netmask=#{subnet.mask} --gateway=#{subnet.gateway} --nameserver=#{[subnet.dns_primary, subnet.dns_secondary].select{ |item| item.present? }.join(',')}" %> --hostname <%= @host %><%= os_major >= 6 ? " --device=#{@host.mac}" : '' -%>

rootpw --iscrypted <%= root_pass %>
<% if @host.param_true?('disable-firewall') -%>
Expand Down
2 changes: 1 addition & 1 deletion provisioning_templates/snippet/coreos_cloudconfig.erb
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ name: coreos_cloudconfig
<% end -%>
<% if @host.params['ssh_authorized_keys'] -%>
ssh_authorized_keys:
<% @host.params['ssh_authorized_keys'].split(',').map(&:strip).each do |ssh_key| -%>
<% @host.params['ssh_authorized_keys'].split(',').map{ |item| item.strip }.each do |ssh_key| -%>
- "<%= ssh_key %>"
<% end -%>
<% else -%>
Expand Down

0 comments on commit 1135f32

Please sign in to comment.