---
name: "PCP_KUBE_PODS"
section: "1"
platform: "linux"
package: "pcp"
version: "7.2.2-2"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/PCP_KUBE_PODS"
---

# PCP\_KUBE\_PODS(1)

list Kubernetes pods to scan for running PCP services

## NAME

**pcp-kube-pods** - list Kubernetes pods to scan for running PCP services

## SYNOPSIS

**$PCP\_BINADM\_DIR/discover/pcp-kube-pods**

## DESCRIPTION

**pcp-kube-pods** uses [**kubectl**(1)](/kubectl/1.md) to provide a list of IP addresses for PODs running in a local Kubernetes cluster, that may be running PCP services like [**pmcd**(1)](/pmcd/1.md) and [**pmproxy**(1)](/pmproxy/1.md).

It is used by the [**pmfind**(1)](/pmfind/1.md) command and the [**pmDiscoverServices**(3)](/pmDiscoverServices/3.md) API as a \`\`shell'' command.

The script invokes the **kubectl get pod** command line (see [**kubectl-get**(1)](/kubectl-get/1.md)) to discover IP addresses for pods. The **.status.podIP** output field is extracted from the Kubernetes pod object(s). Additional options can be specified via configuration file, such as *-l service=database* to restrict the results using Kubernetes pod labels. The default configuration file is **$PCP\_SYSCONF\_DIR/discover/pcp-kube-pods.conf**.

If no local **kubectl** command is found, nothing is reported and an exit code indicating success is returned.

## DIAGNOSTICS

All diagnostics produced are provided by the **kubectl** command.

The **kubectl** exit status is propagated unchanged.

## FILES

- *$PCP\_BINADM\_DIR/discover*

  default path to address discovery commands like **pcp-kube-pods**

- *$PCP\_SYSCONF\_DIR/discover/pcp-kube-pods.conf*

  configuration file containing command line options passed to **kubectl-get**

- *$PCP\_SYSCONF\_DIR/discover/pcp-kube-pods.disabled*

  existence of this file causes the script to report nothing

## PCP ENVIRONMENT

Environment variables with the prefix **PCP\_** are used to parameterize the file and directory names used by PCP. On each installation, the file */etc/pcp.conf* contains the local values for these variables. The **$PCP\_CONF** variable may be used to specify an alternative configuration file, as described in [**pcp.conf**(5)](/pcp.conf/5.md).

## SEE ALSO

[**kubectl-get**(1)](/kubectl-get/1.md), [**kubectl**(1)](/kubectl/1.md), [**pmcd**(1)](/pmcd/1.md), [**pmfind**(1)](/pmfind/1.md), [**pmDiscoverServices**(3)](/pmDiscoverServices/3.md) and [**pcp.env**(5)](/pcp.env/5.md).
