Skip to content

Commit

Permalink
Merge pull request voxpupuli#1407 from smkillen/master
Browse files Browse the repository at this point in the history
Adding resolver entries to streamhost.erb
  • Loading branch information
alexjfisher committed Aug 30, 2020
2 parents 49a3000 + cc421dd commit 80e872c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
6 changes: 6 additions & 0 deletions spec/defines/resource_stream_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,12 @@
value: 'spdy',
match: %r{\s+listen\s+\[::\]:80 spdy;}
},
{
title: 'should set resolver(s)',
attr: 'resolver',
value: ['203.0.113.1', '203.0.113.2'],
match: %r{\s+resolver\s+203.0.113.1 203.0.113.2;}
},
{
title: 'should contain raw_prepend directives',
attr: 'raw_prepend',
Expand Down
3 changes: 3 additions & 0 deletions templates/streamhost/streamhost.erb
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ server {
listen [<%= @ipv6_listen_ip %>]:<%= @ipv6_listen_port %> <% if @ipv6_listen_options %><%= @ipv6_listen_options %><% end %>;
<%- end -%>
<%- end -%>
<%- unless @resolver.empty? -%>
resolver <% @resolver.each do |res| %> <%= res %><% end %>;
<%- end -%>
<% Array(@raw_prepend).each do |line| -%>
<%= line %>
Expand Down

0 comments on commit 80e872c

Please sign in to comment.