Run the Granulate Agent in your Kubernetes cluster as a DaemonSet in order to start learning your application resource usage patterns and optimize your application performance. You can deploy it directly with a DaemonSet object YAML definition.
Take advantage of DaemonSets to deploy the Granulate Agent on all your nodes (or on specific nodes by using nodeSelectors).
1. Create the Granulate gAgent manifest: Install the Granulate Agent on your Kubernetes cluster using the gAgent manifest template. In order to deploy Granulate gAgent using the templates you would need the following parameters:
Docker Hub Secret - Granulte docker hub secret to pull the relevant gAgent docker image deployed
Client ID - A unique customer license key that is required for the agent's authentication.
Service ID - A customer-defined service identifier used to correlate all the agents that are installed in the same customer service.
Note: Those manifests are set for the
granulatenamespace by default. If you are in a custom namespace, update the
metadata.namespaceparameter before applying them.
2. Deploy the gAgent DaemonSet with the command:
kubectl apply -f daemonset_gagent.yaml
3. Verify Deployment: to verify the Granulate gAgent is running in your environment as a DaemonSet execute the following command:
kubectl get daemonset
if the Agent is deployed, you will see output similar to the text below, where
CURRENT are equal to the number of nodes running in your cluster.
NAME DESIRED CURRENT READY UP-TO-DATE AVAILABLE NODE SELECTOR AGEgranulate-agent 2 2 2 2 2 <none> 10s
Find below the list of environment variables available for the Granulate gAgent.
You Granulate API authentication key (required)
A tag to aggregate the agents installed on the same service
Optional setting to configure communication using HTTP/SOCKS5 proxy
Destination site for your K8s collected metrics. Defaults to granulate.io
Optional setting to override the URL for metric submission