For the complete documentation index, see llms.txt. This page is also available as Markdown.

NGINX Ingress Controller

NGINX Ingress Controller is a specialized load balancer for Kubernetes environments. An Ingress Controller is a daemon that runs alongside the NGINX community or plus version. The daemon monitors the NGINX Ingress resources for load-balancing requests across services. The document explains how to configure a Traceable agent for the NGINX Ingress Controller. The following diagram shows a high-level deployment of the Traceable agent for the NGINX Ingress Controller:


Before you begin

Before you begin installing and configuring the Traceable agent, make sure:

  • NGINX Ingress Controller is installed. For example, you can install the latest version of NGINX Ingress Controller by entering the following command:

    ActionScript

    For more information on installing the NGINX Ingress Controller, see NGINX Ingress Controller Installation Guide.

  • Ensure you have installed Traceable platform agent 1.15.0 or later in the Kubernetes environment. For more information, see Helm installation.

  • You should have a basic understanding of and knowledge of the NGINX Ingress Controller.

Traceable Module Extension (tme)

The deployment uses a Traceable Module extension. Traceable module extension (TME) is a type of sidecar container that a Traceable Platform agent can inject into the application pod. It can be considered a miniature Traceable Platform agent.

TME has ext_cap as a component. This synchronously receives requests from applications, such as a gateway. The traceable module extension also houses libtraceable, which has the request-blocking logic. TME is used when native instrumentation or a native plugin is unavailable. In such cases, TME captures data inline and sends it to the Traceable Platform agent asynchronously. TME also blocks the requests inline.


Traceable configuration

Add the traceableai-inject-tme label to the namespace to configure Traceable for the NGINX Ingress Controller. The deployment diagram above shows that the injected Traceable module extension (TME) creates SPANS and sends it to the Traceable Platform agent.

Add label

To add the namespace label for Traceable Module Extension (TME) injection, enter the following command:

ActionScript

TME automatically sets up the NGINX Ingress Lua plugin in the Ingress controller container. TME checks the pod labels to identify the NGINX Ingress Controller. In particular, the labels are:

You can additionally force the TME to set up the NGINX Ingress Controller Lua plugin using a pod annotation. This should be set on the controller pod.


(Optional) ConfigMap name customization

The default ConfigMap name for the Nginx Ingress Controller is ingress-nginx-controller. If the namespace is different from ingress-nginx, the default ConfigMap name is <namespace>-ingress-nginx-controller. You can customize this ConfigMap name and must inform the Traceable Helm values configuration of the new name.

Find the ConfigMap

Enter the following commands to find and inspect the ConfigMap:

  1. Enter the following command to list ConfigMaps in the namespace:

  2. Enter the following command to inspect a ConfigMap:

Example Helm Values Configuration

If you have a customized ConfigMap name and container name, your Helm values configuration will look like this:

Default ConfigMap Structure

Here's an example of how the default ingress-nginx-controller ConfigMap looks:


Restart the deployment

Enter the following command to restart the deployment:


Verification

Enter the following command and verify that the ingress controller has two containers:


Upgrade

To upgrade the Traceable agent, make a note of the points mentioned in the Traceable agent installation, that is:

  • NGINX Lua plugin is set up as part of the setup of the Traceable agent.

  • Make sure that the Traceable agent version is 1.15.0 or later.

Enter the following command to upgrade the Traceable agent using the Helm chart:

Restart the deployment

Enter the following command to restart the deployment:

To verify a successful upgrade, repeat the steps mentioned in the Verification section.


Uninstall

Uninstalling the Traceable agent involves removing the namespace label for TME and restarting the deployment. Complete the following steps:

  1. Remove the namespace label for Traceable Module Extension (TME) injection. Enter the following command:

    ActionScript

  2. Restart the deployment:

    ActionScript

  3. Verify that ingress-controller has one container:

    ActionScript

Last updated

Was this helpful?