Files
gost/tests/e2e/testdata/ingress/client.yaml
T
ginuerzh 1fd69ac704 test(e2e): add ingress module e2e test suite
Verifies hostname→endpoint routing at the reverse-proxy tunnel
entrypoint. A public gost runs a tunnel handler with an ingress
mapping example.local→tunnel-UUID and an HTTP entrypoint; an internal
client binds a reverse tunnel forwarding to the echo server. A request
with a mapped Host is routed through the tunnel to the echo server,
while an unmapped Host matches no ingress rule and is rejected.
2026-07-16 20:53:30 +08:00

38 lines
967 B
YAML

# Internal client behind NAT: binds a reverse tunnel (tunnel.id matches the
# server's ingress endpoint) and forwards tunneled connections to the echo
# server. The tunnel server is reached via chain-0's tunnel connector.
#
# service-1 is a dummy TCP listener on a fixed port; the rtcp reverse-tunnel
# listener binds remotely through the chain and opens no local port, so this
# gives the e2e harness a stable port to wait on.
services:
- name: service-0
addr: ":0"
handler:
type: rtcp
listener:
type: rtcp
chain: chain-0
forwarder:
nodes:
- addr: tcp-echo:5678
- name: service-1
addr: ":8423"
handler:
type: http
listener:
type: tcp
chains:
- name: chain-0
hops:
- nodes:
- addr: gost-server:8421
connector:
type: tunnel
metadata:
tunnel.id: 6be39003-f4fa-49e4-a6ef-1997684d160e
dialer:
type: tcp