Files
@ 0f349663e20c
Branch filter:
Location: majic-ansible-roles/testsite/playbooks/roles/wsgihello/files/hello.wsgi - annotation
0f349663e20c
740 B
text/plain
MAR-30: Fixes for multiple platforms and more extensive testing:
- Include instructions on how to run tests against different platforms (Debian
versions).
- Use correct base box for Debian Stretch when testing role 'preseed'.
- Use fixed hostnames when runnig teets for role 'preseed'.
- Make sure to test preseed configuration file when providing overrides for a
host that does not include overrides as well in role 'preseed'.
- Include instructions on how to run tests against different platforms (Debian
versions).
- Use correct base box for Debian Stretch when testing role 'preseed'.
- Use fixed hostnames when runnig teets for role 'preseed'.
- Make sure to test preseed configuration file when providing overrides for a
host that does not include overrides as well in role 'preseed'.
052eefc4fab0 052eefc4fab0 b757d690af42 b757d690af42 052eefc4fab0 052eefc4fab0 052eefc4fab0 0ec59430e00c 0ec59430e00c 0ec59430e00c 0ec59430e00c 0ec59430e00c 0ec59430e00c 0ec59430e00c 0ec59430e00c 0ec59430e00c 67dd87d59abb 0ec59430e00c 0ec59430e00c 0ec59430e00c 67dd87d59abb 67dd87d59abb 0ec59430e00c 0ec59430e00c 052eefc4fab0 052eefc4fab0 052eefc4fab0 052eefc4fab0 | #!/usr/bin/env python
import os
def application(environ, start_response):
status = '200 OK'
template = """<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>{title}</title>
</head>
<body>
<h1>Hello, world!</h1>
<p>I am website {title}</p>
<p>Accept-Encoding header was set to {acceptencoding}</p>
</body>
</html>
"""
output = template.format(title=os.environ.get("WEBSITE_NAME", "that nobody set a name for :("),
acceptencoding=environ.get("HTTP_ACCEPT_ENCODING"))
response_headers = [('Content-type', 'text/html'),
('Content-Length', str(len(output)))]
start_response(status, response_headers)
return [output]
|