PCP_KUBE_PODS(1)

πŸ“¦
version 7.2.2 Β· 3 versions
, in arch rolling, centos-stream 10, fedora 43, fedora 44, ubuntu resolute, ubuntu stonking

πŸ’– PCP_KUBE_PODS(1) πŸ’–

✨ NAME ✨

okay bestie, the big reveal is pcp-kube-pods, and it lists Kubernetes pods to scan for running PCP services πŸ¦‹ total scavenger hunt energy 🧚

🌸 SYNOPSIS 🌸

$PCP_BINADM_DIR/discover/pcp-kube-pods

πŸ”₯ DESCRIPTION πŸ”₯

this one is lowkey so cool, ngl. pcp-kube-pods uses kubectl(1) to hand you a list of IP addresses for PODs running in a local Kubernetes cluster πŸ’… those PODs might be running PCP services like pmcd(1) and pmproxy(1) πŸ‘‘

it's used by pmfind(1) and the pmDiscoverServices(3) API as a "shell" command. main character behavior πŸŽ€

the script runs the kubectl get pod command line (see kubectl-get(1)) to find those IP addresses. it grabs the .status.podIP output field out of the Kubernetes pod object(s) ✨ you can tack on extra options through a configuration file, like -l service=database, to narrow the results using Kubernetes pod labels 🫢 the default configuration file is $PCP_SYSCONF_DIR/discover/pcp-kube-pods.conf 🌈

plot twist: if there's no local kubectl command, nothing gets reported and an exit code indicating success comes back. no drama πŸ™ˆ

πŸ’€ DIAGNOSTICS πŸ’€

all the diagnostics you'll see come straight from the kubectl command, so if something's sus, that's where it's coming from πŸ”

and the kubectl exit status gets passed along unchanged. no edits, no filter, just vibes πŸ’œ


πŸ“ FILES πŸ“

  • $PCP_BINADM_DIR/discover β€” the default path to address discovery commands like pcp-kube-pods πŸ“
  • $PCP_SYSCONF_DIR/discover/pcp-kube-pods.conf β€” the config file holding the command line options passed along to kubectl-get πŸŽ€
  • $PCP_SYSCONF_DIR/discover/pcp-kube-pods.disabled β€” if this file exists, the script reports nothing. the off switch, bestie πŸ™…β€β™€οΈ

🌈 PCP ENVIRONMENT 🌈

environment variables with the prefix PCP_ are used to parameterize the file and directory names PCP uses, so they're basically the boss of the paths πŸ‘‘ on each installation, the file /etc/pcp.conf holds the local values for these variables. want a different config file? the $PCP_CONF variable lets you point to one, as described in pcp.conf(5) 🧚


πŸ¦‹ SEE ALSO πŸ¦‹

kubectl-get(1), kubectl(1), pmcd(1), pmfind(1), pmDiscoverServices(3) and pcp.env(5) πŸ’–


that's the tea β˜• this page is from the Performance Co-Pilot (PCP) manual, PCP_KUBE_PODS(1) edition, and I'm obsessed. love you bestie πŸ«ΆπŸ’œ

πŸ“¦ where this page comes from