Add a check for custom host to ingress TLS integration test
This commit is contained in:
parent
bebf1d5df9
commit
a198282349
|
@ -12,10 +12,11 @@ config_entries {
|
|||
listeners = [
|
||||
{
|
||||
port = 9999
|
||||
protocol = "tcp"
|
||||
protocol = "http"
|
||||
services = [
|
||||
{
|
||||
name = "s1"
|
||||
hosts = ["test.example.com"]
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
@ -32,3 +32,12 @@ load helpers
|
|||
[ "$status" -eq 0 ]
|
||||
[ "$output" = "hello" ]
|
||||
}
|
||||
|
||||
@test "should be able to connect to s1 through the TLS-enabled ingress port using the custom host" {
|
||||
assert_dnssan_in_cert localhost:9999 'test.example.com'
|
||||
run retry_default curl --cacert <(get_ca_root) -s -f -d hello \
|
||||
--resolve test.example.com:9999:127.0.0.1 \
|
||||
https://test.example.com:9999
|
||||
[ "$status" -eq 0 ]
|
||||
[ "$output" = "hello" ]
|
||||
}
|
Loading…
Reference in New Issue