From 22bda562988b6d1cceca4cf00cd13290a5dbc01c Mon Sep 17 00:00:00 2001 From: Sergio Oliveira Date: Mon, 4 May 2015 18:27:21 -0300 Subject: [PATCH] Allow postgresql and redis connections --- cookbooks/firewall/templates/host-database/iptables-filter.erb | 7 +++++++ 1 file changed, 7 insertions(+), 0 deletions(-) create mode 100644 cookbooks/firewall/templates/host-database/iptables-filter.erb diff --git a/cookbooks/firewall/templates/host-database/iptables-filter.erb b/cookbooks/firewall/templates/host-database/iptables-filter.erb new file mode 100644 index 0000000..d474b54 --- /dev/null +++ b/cookbooks/firewall/templates/host-database/iptables-filter.erb @@ -0,0 +1,7 @@ + +# Allow access to PostgreSQL +-A INPUT -s <%= node['peers']['integration'] %> -p tcp -m state --state NEW --dport 5432 -j ACCEPT +-A INPUT -s <%= node['peers']['social'] %> -p tcp -m state --state NEW --dport 5432 -j ACCEPT + +# Allow access to Redis +-A INPUT -s <%= node['peers']['integration'] %> -p tcp -m state --state NEW --dport 6379 -j ACCEPT -- libgit2 0.21.2