OLD | NEW |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # coding: utf-8 | |
3 | 2 |
4 # This file is part of the Adblock Plus web scripts, | 3 # This file is part of the Adblock Plus web scripts, |
5 # Copyright (C) 2006-2016 Eyeo GmbH | 4 # Copyright (C) 2006-2016 Eyeo GmbH |
6 # | 5 # |
7 # Adblock Plus is free software: you can redistribute it and/or modify | 6 # Adblock Plus is free software: you can redistribute it and/or modify |
8 # it under the terms of the GNU General Public License version 3 as | 7 # it under the terms of the GNU General Public License version 3 as |
9 # published by the Free Software Foundation. | 8 # published by the Free Software Foundation. |
10 # | 9 # |
11 # Adblock Plus is distributed in the hope that it will be useful, | 10 # Adblock Plus is distributed in the hope that it will be useful, |
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of | 11 # but WITHOUT ANY WARRANTY; without even the implied warranty of |
(...skipping 12 matching lines...) Expand all Loading... |
25 bindAddress = os.environ.get('FCGI_BIND_ADDRESS') | 24 bindAddress = os.environ.get('FCGI_BIND_ADDRESS') |
26 if bindAddress: | 25 if bindAddress: |
27 match = re.search(r'^(.*?):(\d+)$', bindAddress) | 26 match = re.search(r'^(.*?):(\d+)$', bindAddress) |
28 if match: | 27 if match: |
29 bindAddress = (match.group(1), int(match.group(2))) | 28 bindAddress = (match.group(1), int(match.group(2))) |
30 | 29 |
31 srv = WSGIServer(multiplex, debug=False, bindAddress=bindAddress) | 30 srv = WSGIServer(multiplex, debug=False, bindAddress=bindAddress) |
32 | 31 |
33 if __name__ == '__main__': | 32 if __name__ == '__main__': |
34 srv.run() | 33 srv.run() |
OLD | NEW |