Skip to content
Snippets Groups Projects
Commit f16a65e6 authored by Stéphane Diemer's avatar Stéphane Diemer
Browse files

PEP8

parent 2392afd1
No related branches found
No related tags found
No related merge requests found
......@@ -46,11 +46,13 @@ def check_listening_port():
print_green('Postfix is listening port 25 correctly.')
return True
def check_spf(ip):
status, output = subprocess.getstatusoutput('host -t TXT ubicast.eu')
if ip in output:
return True
def check_relay():
print('Checking if SMTP relay conforms to conf.')
status, out = subprocess.getstatusoutput('grep relayhost /etc/postfix/main.cf')
......@@ -60,7 +62,7 @@ def check_relay():
configured_relay = None
if not configured_relay:
# no relay configured, check relayless situations
domain = '.'.join(conf.get('MS_SERVER_NAME').split('.')[-2:])
# domain = '.'.join(conf.get('MS_SERVER_NAME').split('.')[-2:])
ip = conf.get('NETWORK_IP_NAT')
if not ip:
ip = conf.get('NETWORK_IP')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment