Kubernetes Integration

JFrog Pipelines Documentation

ft:sourceType
Paligo

The Kubernetes Integration is used to connect JFrog Pipelines platform to self-hosted Kubernetes clusters so that you can deploy Docker based applications.

A Kubernetes integration can be used for these purposes:

  • To deploy builds to nodes in Kubernetes clusters from pipelines using a HelmChart resource with the HelmDeploy step.

  • To enable Pipelines to create and destroy build nodes in Kubernetes clusters on demand through a dynamic node pool.

Creating a Kubernetes Integration

Kubernetes Integration can be added as:

  • A Pipeline integration, to use Kubernetes for deploying builds from a pipeline

  • An Admin integration, to use Kubernetes for a dynamic node pool

For more information, see Adding an Integration.

Here is the information you need to create this integration:

  • Name -- choose a friendly name for the integration

  • Kube Config -- configuration YAML to access Kubernetes cluster

    Note

    The Kube Config file should include the following permissions:

    • Create/scale/destroy Deployments

    • Create/delete PVCs

    • Create/delete Secrets

    • Create/delete ConfigMaps

      Note that ConfigMaps is required only when user is using the insecure docker registries feature.

    Tip

    If you encounter issues, consider simplifying your kubeconfig file by including just one context and user, as having multiple contexts and users can lead to problems.

Usage

The Kubernetes integration can also be added directly to a step in the integrations section. This automatically configures the kubectl command line interface with access to the Kubernetes cluster.

Default Environment Variables

When you create a resource with this integration, and create a step that uses it, a set of environment variables is automatically made available.

Environment variable

Description

res_<resource-name>_kubernetesConfig_kubeconfig

Kubernetes cluster configuration

When add this integration directly to a step, a set of environment variables is automatically made available.

Environment variable

Description

int_<integration-name>_kubeconfig

Kubernetes cluster configuration