(self, env)
| 74 | assert r.json['host'] == seen |
| 75 | |
| 76 | def test_proxy_01_003(self, env): |
| 77 | domain = f"test1.{env.http_tld}" |
| 78 | conf = HttpdConf(env) |
| 79 | conf.add([ |
| 80 | "ProxyPreserveHost on", |
| 81 | "<Proxy balancer://backends>", |
| 82 | f" BalancerMember https://localhost:{env.https_port}", |
| 83 | " SSLProxyEngine on", |
| 84 | "</Proxy>", |
| 85 | ]) |
| 86 | conf.start_vhost(domains=[domain], port=env.https_port, doc_root="htdocs/test1") |
| 87 | conf.add([ |
| 88 | "ProxyPass /proxy balancer://backends", |
| 89 | "ProxyPassReverse /proxy balancer://backends", |
| 90 | ]) |
| 91 | conf.end_vhost() |
| 92 | conf.install() |
| 93 | assert env.apache_restart() == 0 |
| 94 | r = env.curl_get(f"https://{domain}:{env.https_port}/proxy/alive.json", 5) |
| 95 | assert r.response["status"] == 200 |
| 96 | assert r.json['host'] == "test1" |
nothing calls this directly
no test coverage detected