Install Observe Agent on Kubernetes¶
Note
The Observe Agent on Kubernetes is designed to deliver the best-in-class user experience with Kubernetes Explorer, which is currently in private preview. For more details on Kubernetes Explorer, use the Contact Support button within the product. Navigate to Docs & Support on the left menu, select Contact Support, and click Send Us a Message to reach an Observe Data Engineer.
You may follow the instructions on this page to deploy the Observe Agent on Kubernetes, allowing you to gather raw events, logs, and metrics from Kubernetes.
If you’re interested in using the built-in dashboards, please refer to the Kubernetes App.
Add the Observe Helm repository¶
Run the following commands to add the Observe Helm repository to your local Helm setup, allowing you to access and deploy Observe’s charts.
helm repo add observe https://observeinc.github.io/helm-charts
helm repo update
Deploy the Observe Agent¶
Run the following commands to create a Kubernetes namespace called observe
and generate a secret. Replace ${OBSERVE_TOKEN}
with your instance’s token (ex: a1b2c3d4e5f6g7h8i9k0:l1m2n3o4p5q6r7s8t9u0v1w2x3y4z5a6).
kubectl create namespace observe
kubectl -n observe create secret generic agent-credentials --from-literal=OBSERVE_TOKEN=${OBSERVE_TOKEN}
kubectl annotate secret agent-credentials -n observe \
meta.helm.sh/release-name=observe-agent \
meta.helm.sh/release-namespace=observe
kubectl label secret agent-credentials -n observe \
app.kubernetes.io/managed-by=Helm
Run the following command to deploy the Observe Agent in the observe
namespace using observe-agent-monitored-cluster
as the name for your Kubernetes cluster. Replace ${OBSERVE_COLLECTION_ENDPOINT}
with your instance’s collection endpoint (ex: https://123456789012.collect.observeinc.com/). For more information on configuring the agent, see values.yaml.
helm install observe-agent observe/agent -n observe \
--set observe.token.create="false" \
--set observe.collectionEndpoint.value="${OBSERVE_COLLECTION_ENDPOINT}" \
--set cluster.name="observe-agent-monitored-cluster" \
--set cluster.events.enabled="true" \
--set cluster.metrics.enabled="true" \
--set node.containers.logs.enabled="true" \
--set node.containers.metrics.enabled="true" \
--set application.prometheusScrape.enabled="false" \
--set agent.selfMonitor.enabled="true"
Run the following command to make sure the Observe Agent has been deployed successfully.
kubectl get pods -n observe
Run the following command to save the current configuration values to a file for future configuration adjustments and upgrades.
helm -n observe get values observe-agent -o yaml > observe-agent-values.yaml
Create observe-agent-values.yaml
with the following configuration. Replace ${OBSERVE_COLLECTION_ENDPOINT}
with your instance’s collection endpoint (ex: https://123456789012.collect.observeinc.com/). For more information on configuring the agent, see values.yaml.
agent:
selfMonitor:
enabled: true
application:
prometheusScrape:
enabled: false
cluster:
events:
enabled: true
metrics:
enabled: true
name: observe-agent-monitored-cluster
node:
containers:
logs:
enabled: true
metrics:
enabled: true
observe:
collectionEndpoint:
value: ${OBSERVE_COLLECTION_ENDPOINT}
token:
create: false
Run the following command to deploy the Observe Agent in the observe
namespace
helm install observe-agent observe/agent -n observe --values observe-agent-values.yaml
Run the following command to make sure the Observe Agent has been deployed successfully.
kubectl get pods -n observe
Uninstall the Observe Agent¶
You can uninstall the agent from your Kubernetes cluster.
helm uninstall observe-agent -n observe
kubectl -n observe delete secret agent-credentials
kubectl delete namespace observe