Commit 75bc8d67 authored by Romain Courteaud's avatar Romain Courteaud

Force ipv4 for production configuration

parent 270da7b2
...@@ -37,13 +37,13 @@ import logging ...@@ -37,13 +37,13 @@ import logging
import zc.buildout import zc.buildout
def validLoopBackAddress(ip): def validLoopBackAddress(ip):
if netaddr.IPAddress(ip).is_loopback(): if netaddr.IPAddress(ip).is_loopback() and netaddr.valid_ipv4(ip):
return True return True
else: else:
return False return False
def validPublicAddress(ip): def validPublicAddress(ip):
return not validLoopBackAddress(ip) return (not validLoopBackAddress(ip)) and netaddr.valid_ipv4(ip):
class Recipe: class Recipe:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment