Move the firewall rule for sockethub to its own recipe

This commit is contained in:
Greg Karékinian 2019-04-10 16:33:56 +02:00
parent 39744f517f
commit e0aa4c5b11
2 changed files with 19 additions and 9 deletions

View File

@ -0,0 +1,18 @@
#
# Cookbook Name:: sockethub
# Recipe:: _firewall
#
# Copyright 2015-2019, Kosmos
#
# All rights reserved - Do Not Redistribute
#
unless node.chef_environment == "development"
include_recipe "firewall"
firewall_rule 'sockethub' do
port node['sockethub']['external_port'].to_i
protocol :tcp
command :allow
end
end

View File

@ -7,15 +7,7 @@
# All rights reserved - Do Not Redistribute
#
unless node.chef_environment == "development"
include_recipe "firewall"
firewall_rule 'sockethub' do
port node['sockethub']['external_port'].to_i
protocol :tcp
command :allow
end
end
include_recipe 'sockethub::_firewall'
include_recipe 'kosmos-nginx'
server_name = node['sockethub']['nginx']['server_name']