Skip to main content
Version: Release 24.3

Kubernetes Container Plugin

The Kubernetes container plugin offers a range of functionalities to enhance Kubernetes cluster management, deployment, and operations.

important

You must set up a connection to the Kubernetes server before adding AWS tasks. For more information, see Set up Connection to Kubernetes Server.

note

In the release flow editor, Container tasks have a blue border.

Kubernetes provides the following features:

  • Apply Command (Container)
  • Check Resource Readiness (Container)
  • Check Status of Pods in Namespace (Container)
  • Check if Namespace Exists (Container)
  • Create Annotation for Resource (Container)
  • Create ConfigMap (Container)
  • Create Label for Resource (Container)
  • Create Namespace (Container)
  • Create Secret (Container)
  • Delete Annotation for Resource (Container)
  • Delete ConfigMap (Container)
  • Delete Label for Resource (Container)
  • Delete Namespace (Container)
  • Delete Secret (Container)
  • Execute Command (Container)
  • Fetch Resources as YAML (Container)
  • Get Annotation for Resource (Container)
  • Get ConfigMap by Name in Namespace (Container)
  • Get Label for Resource (Container)
  • Get Secret by Name in Namespace (Container)
  • List Annotation for Resource (Container)
  • List all Namespaces (Container)
  • List all Services in Namespace (Container)
  • Patch ConfigMap (Container)
  • Patch Resource (Container)
  • Patch Secret (Container)
  • Update Annotation for Resource (Container)
  • Update ConfigMap (Container)
  • Update Label for Resource (Container)
  • Update Secret (Container)
  • Wait for Resource Conditions (Container)

Prerequisites

For Kubernetes integration, you need the following:

  • Kubernetes server running and accessible via HTTP(s)
  • Digital.ai Release Runner setup to run the container tasks

Set up Connection to Kubernetes Server

  1. From the navigation pane, under CONFIGURATION, click Connections.
  2. Under HTTP Server connections, next to Kubernetes API Server (Container), click add button. The New Kubernetes API Server (Container) page opens.
  3. In the Title field, enter a name for the configuration.
  4. In the URL field, enter the URL of the Kubernetes API server.
  5. In the Authentication method drop-down list, select the required authentication option. The options are as follows:
    • Token
    • Client Certificate
    • OAuth2 Client Credentials
    • OIDC Flow Note that, some additional fields will be enabled based on the authentication option selected.
  6. If you want to connect to the server, without validating the TLS certificate, select the Insecure checkbox.
  7. In the Certificate Authority field, enter the trusted root certificate for server in base64 format.
  8. In the QPS field, enter a value to define the maximum queries that can be sent per second to the master from this client.
  9. In the Burst field, enter a value to define the maximum burst capacity allowed for a specific resource, such as API requests, within a given time frame.
  10. In the Provider Type drop-down list, select the cloud provider. The options are as follows:
  • AWS
  • GCP
  • Azure
  1. In the Bearer Token field, enter the bearer token for authentication. You can also add the variable here.
  2. To test the connection, click Test.
  3. To save the configuration, click Save.

Create Kubernetes server

Apply Command (Container)

The Apply Command (Container) task creates or updates resources defined in a Kubernetes configuration file.

  1. In the release flow tab of a Release template, add a task of type Kubernetes > Apply Command (Container).
  2. Click the added task to open it.
  3. In the Capabilities field, enter a value that matches the capability set for your Runner. This will help you to route jobs to that particular Runner.
  4. In the Server field, select the configured Kubernetes server.
  5. In the Namespace field, enter a Kubernetes namespace in which the target pod is located.
  6. In the Yaml Location field, enter the location of the Kubernetes YAML file.
  7. In the Yaml Content field, enter the content of the Kubernetes YAML file.

Execute Command (Container)

Execute Command (Container)

The Execute Command (Container) task enables you to directly execute commands within a container running in a Kubernetes pod.

  1. In the release flow tab of a Release template, add a task of type Kubernetes > Execute Command (Container).
  2. Click the added task to open it.
  3. In the Capabilities field, enter a value that matches the capability set for your Runner. This will help you to route jobs to that particular Runner.
  4. In the Server field, select the configured Kubernetes server.
  5. In the Namespace field, enter a Kubernetes namespace in which the target pod is located.
  6. In the Pod Name field, enter the name of the pod in which the command will be executed.
  7. In the Container Name field, enter the name of the container inside the pod in which the command will be executed.
  8. In the Command field, enter the command to be executed within the specified container of the selected pod.

Execute Command (Container)

Check Resource Readiness (Container)

This task checks the readiness of a resource. It is used to ensure that a specific resource is fully operational and ready for use.

check resource

Check Status of Pods in Namespace (Container)

This task checks the status of pods in a namespace. It is used to monitor the health and running state of all pods within a given namespace.

check status

Check if Namespace Exists (Container)

This task checks if a namespace exists. It is used to verify the presence of a specific namespace in the cluster.

check namespace

Create Annotation for Resource (Container)

This task creates an annotation for a resource. It is used to add metadata to a resource for identification or informational purposes.

check annotation

Create ConfigMap (Container)

This task creates a ConfigMap. It is used to store configuration data as key-value pairs for applications to consume.

check configmap

Create Label for Resource (Container)

This task creates a label for a resource. It is used to tag resources for organization, selection, and filtering.

check label

Create Namespace (Container)

This task creates a namespace. It is used to create a new namespace to isolate resources within a cluster.

check namespace

Create Secret (Container)

This task creates a secret. It is used to store sensitive data, such as passwords or tokens, securely.

check secret

Delete Annotation for Resource (Container)

This task deletes an annotation for a resource. It is used to remove metadata from a resource.

delete annotation

Delete ConfigMap (Container)

This task deletes a ConfigMap. It is used to remove a ConfigMap from the cluster.

delete configmap

Delete Label for Resource (Container)

This task deletes a label for a resource. It is used to remove a tag from a resource.

delete label

Delete Namespace (Container)

This task deletes a namespace. It is used to remove a namespace and its contained resources from the cluster.

delete namespace

Delete Secret (Container)

This task deletes a secret. It is used to remove sensitive data from the cluster.

delete secret

Fetch Resource as YAML (Container)

This task fetches a resource as YAML. It is used to retrieve the definition of a resource in YAML format for review or processing.

fetch resource

Get Annotation for Resource (Container)

This task gets an annotation for a resource. It is used to retrieve metadata associated with a specific resource.

get annotation

Get ConfigMap by Name in Namespace (Container)

This task gets a ConfigMap by name in a namespace. It is used to retrieve a specific ConfigMap within a given namespace.

get configmap

Get Label for Resource (Container)

This task gets a label for a resource. It is used to retrieve the tags associated with a specific resource.

get label

Get Secret by Name in Namespace (Container)

This task gets a secret by name in a namespace. It is used to retrieve a specific secret within a given namespace.

get secret

List Annotations for Resource (Container)

This task lists annotations for a resource. It is used to display all metadata associated with a specific resource.

list annotation

List Labels for Resource (Container)

This task lists labels for a resource. It is used to display all tags associated with a specific resource.

list labels

List all Namespaces (Container)

This task lists all namespaces. It is used to display all namespaces within a cluster.

list namespaces

List all Services in Namespace (Container)

This task lists all services in a namespace. It is used to display all services within a given namespace.

list services

Patch ConfigMap (Container)

This task patches a ConfigMap. It is used to update specific fields of an existing ConfigMap.

patch configmap

Patch Resource (Container)

This task patches a resource. It is used to update specific fields of an existing resource.

patch resource

Patch Secret (Container)

This task patches a secret. It is used to update specific fields of an existing secret.

patch secret

Update Annotation for Resource (Container)

This task updates an annotation for a resource. It is used to modify the metadata associated with a resource.

update annotation

Update ConfigMap (Container)

This task updates a ConfigMap. It is used to replace an existing ConfigMap with a new definition.

update configmap

Update Label for Resource (Container)

This task updates a label for a resource. It is used to modify the tags associated with a resource.

update label

Update Secret (Container)

This task updates a secret. It is used to replace an existing secret with a new definition.

update secret

Wait for Resource Conditions (Container)

This task waits for specific conditions on a resource (such as a Pod, Deployment, or Service) to be met before proceeding. It ensures that the resource is in the desired state before continuing with further actions.

Wait for Resource Conditions

List Persistent Volumes (Container)

This task lists persistent volumes in the cluster. It is used to provide an overview of all persistent volumes available for storage.

List Persistent Volume

Get Persistent Volume (Container)

This task gets persistent volumes in the cluster. It is used to retrieve details about specific persistent volumes.

Get Persistent Volume

Create Persistent Volume (Container)

This task creates persistent volumes in the cluster. It is used to allocate new storage resources for use by applications.

Create Persistent Volume

Update Persistent Volume (Container)

This task updates persistent volumes in the cluster. It is used to modify existing persistent volumes, such as changing their size or configuration.

update volumes

Delete Persistent Volume (Container)

This task deletes persistent volumes in the cluster. It is used to remove storage resources that are no longer needed.

Delete Persistent Volume

List Persistent Volume Claims (Container)

This task lists persistent volume claims in the cluster. It is used to provide an overview of all claims requesting storage resources.

List Persistent Volume Claims

Get Persistent Volume Claim (Container)

This task gets persistent volume claims in the cluster. It is used to retrieve details about specific volume claims.

Get Persistent Volume Claim

Create Persistent Volume Claim (Container)

This task creates persistent volume claims in the cluster. It is used to request storage resources from available persistent volumes.

Create Persistent Volume Claim

Update Persistent Volume Claim (Container)

This task updates persistent volume claims in the cluster. It is used to modify existing claims, such as adjusting their requested size.

Update Persistent Volume Claim

Delete Persistent Volume Claim (Container)

This task deletes persistent volume claims in the cluster. It is used to remove claims that are no longer needed, freeing up associated storage resources.

Delete Persistent Volume Claim