From a929e2e07391e987833f8e5970b50a1ec5e18f14 Mon Sep 17 00:00:00 2001 From: justngrok Date: Wed, 30 Oct 2024 12:58:54 -0600 Subject: [PATCH] Update v3.mdx (#1003) Resolves ngrok-private/ngrok#33865 Update example and url for endpoints to include TCP and TLS. --- docs/agent/config/v3.mdx | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/docs/agent/config/v3.mdx b/docs/agent/config/v3.mdx index 49d852cf6..ad0844317 100644 --- a/docs/agent/config/v3.mdx +++ b/docs/agent/config/v3.mdx @@ -316,7 +316,7 @@ endpoint configuration options can be found here. ### Example -In the snippet below we are defining two endpoints named 'httpbin' and 'demo': +In the snippet below we are defining two HTTPS endpoints, one TCP endpoint, and one TLS endpoint named 'httpbin', 'demo', 'ssh', and 'demo-2': ```yaml endpoints: @@ -328,6 +328,14 @@ endpoints: url: https://demo.inconshreveable.com upstream: url: 8181 + - name: ssh + url: tcp://1.tcp.ngrok.io:12345 + upstream: + url: 22 + - name: demo-2 + url: tls://myexample.ngrok.app + upstream: + url: 443 ``` #### Start the endpoint named 'httpbin' @@ -379,9 +387,9 @@ String. The address you would like to use to forward traffic to your upstream se - **Domain** - `example.org` - When using the _domain_ format you are only defining the domain. The scheme and port will be inferred. -- **Origin** - `https://example.ngrok.app` _or_ `https://example.ngrok.app:443` - - When using the _origin_ format you are defining the protocol, domain and port. -- **Scheme (shorthand)** - `https://` +- **Origin** - `https://example.ngrok.app` _or_ `https://example.ngrok.app:443` _or_ `tcp://1.tcp.ngrok.io:12345` _or_ `tls://example.ngrok.app` + - When using the _origin_ format you are defining the protocol, domain and port. HTTP endpoints accept ports `80` or `443` with respective protocol. +- **Scheme (shorthand)** - `https://` _or_ `tcp://` _or_ `tls://` _or_ `http://` - When using _scheme_ you are defining the protocol and will receive back a randomly assigned ngrok address. - **Empty** - `` - When _empty_ your endpoint will default to be `https` and receive back a randomly assigned ngrok address.