Kubernetes has the concept of Custom Resource Definitions (CRDs) which allow you to define your own custom resources. This document will cover the CRDs you might use to achieve your goals with the ngrok Kubernetes Operator.
Warning: There are other CRDs not documented here that are used internally by the controller. It is not recommended to edit these, but inspecting them to query the state of the system could be useful at times. See the internal CRDs document for more details.
Ngrok Module Sets
NgrokModuleSets
is a CRD that lets you define combinations of ngrok modules that can be set on your ingress objects and applied to all of their routes. For an in-depth guide on configuring NgrokModuleSets
see the Route Modules Guide.
NgrokModuleSetModules
Field | Type | Description |
---|
compression | EndpointCompression | Configuration for compression for this module |
headers | EndpointHeaders | Configuration for headers for this module |
ipRestriction | EndpointIPPolicy | Configuration for IP restriction for this module |
tlsTermination | EndpointTLSTerminationAtEdge | Configuration for TLS termination for this module |
webhookVerification | EndpointWebhookVerification | Configuration for webhook verification for this module |
NgrokModuleSet
Field | Type | Description |
---|
apiVersion | string | API version of the NgrokModuleSet custom resource definition |
kind | string | Kind of the custom resource definition |
metadata | ObjectMeta | Standard Kubernetes metadata |
modules | NgrokModuleSetModules | The set of modules for this custom resource definition |
NgrokTrafficPolicy
Field | Type | Description |
---|
apiVersion | string | API version of the NgrokTrafficPolicy |
kind | string | Kind of the custom resource definition |
metadata | ObjectMeta | Standard Kubernetes metadata |
policy | json.RawMessage | See policy configuration |
EndpointCompression
Field | Type | Description |
---|
enabled | boolean | Whether or not compression is enabled for this endpoint |
EndpointIPPolicy
Field | Type | Description |
---|
ippolicies | []string | List of IP policies for this endpoint |
Field | Type | Description |
---|
add | map[string]string | Map of header key to header value that will be injected into the HTTP Request |
remove | []string | List of header names that will be removed from the HTTP Request |
Field | Type | Description |
---|
add | map[string]string | Map of header key to header value that will be injected into the HTTP Response |
remove | []string | List of header names that will be removed from the HTTP Response |
Field | Type | Description |
---|
request | EndpointRequestHeaders | Configuration for request headers for this endpoint |
response | EndpointResponseHeaders | Configuration for response headers for this endpoint |
EndpointTLSTerminationAtEdge
Field | Type | Description |
---|
minVersion | string | Minimum TLS version to allow for connections to the edge |
SecretKeyRef
Field | Type | Description |
---|
name | string | Name of the Kubernetes secret |
key | string | Key in the secret to use |
EndpointWebhookVerification
Field | Type | Description |
---|
provider | string | String indicating which webhook provider will be sending webhooks to this endpoint |
secret | SecretKeyRef | Reference to a secret containing the secret used to validate requests from the given provider |
IP Policies