Download PDF
Download page Cluster Agent Container Image.
Cluster Agent Container Image
This page describes how to build a custom Cluster Agent container image or use an officially released pre-built images and store it to an internal registry.
This procedure is required when you:
- Require to build custom Cluster Agent container image
- Require to use the pre-built Cluster Agent Image from DockerHub, or the RedHat Container Registry, and store it in the internal registry.
Otherwise, you can directly pull and use the pre-built Cluster Agent Container Images on the Splunk AppDynamics DockerHub repository or Splunk AppDynamics RedHat registry in the cluster-agent.yaml
or values.yaml
Helm file.
This example uses the pre-built Cluster Agent Image 21.12.0 published to DockerHub:
apiVersion: cluster.appdynamics.com/v1alpha1
kind: Clusteragent
metadata:
name: k8s-cluster-agent
namespace: appdynamics
spec:
controllerUrl: "http://<account>.saas.appdynamics.com"
account: "<account-name>"
appName: "Cluster1"
image: docker.io/appdynamics/cluster-agent:21.12.0
deploymentMode: PRIMARY
installclusteragent: true
installInfraviz: false
# Docker images
imageInfo:
agentImage: docker.io/appdynamics/cluster-agent
agentTag: 21.12.0
operatorImage: docker.io/appdynamics/cluster-agent-operator
operatorTag:21.12.0
imagePullPolicy: Always
machineAgentImage: docker.io/appdynamics/machine-agent-analytics
machineAgentTag:21.9.0
machineAgentWinTag:21.9.0-win-ltsc2019
netVizImage: docker.io/appdynamics/machine-agent-netviz
Build the Custom Cluster Agent Image
The download packages from the Download Portal include files you need to build and deploy the Cluster Agent container image.
Depending on the base Image that was used to build the Cluster Agent Image, there are two package types available on the portal:
- Alpine Linux-based
- Rhel Linux-based (recommended for OpenShift cluster only)
The directory structure of the download packages for the Alpine and Rhel Linux is:
cluster-agent
├── cluster-agent-operator.yaml
├── appdynamics-operator-alpine-linux-amd64-21.12.0-88
├── cluster-agent-operator-openshift-1.15-or-less.yaml
├── cluster-agent-operator-openshift.yaml
├── cluster-agent.yaml
├── infraviz.yaml
├── infraviz-pod-security-policy.yaml
├── infraviz-security-context-constraint-openshift.yaml
├── README-alpine.md
└── docker
├── cluster-agent.zip
├── Dockerfile
├── LICENSE
└── start-appdynamics
└── helm-charts
├── Chart.yaml
├── README.md
├── crds
├── templates
└── values.yaml
cluster-agent
├── cluster-agent-operator.yaml
├── appdynamics-operator-alpine-linux-arm64-21.12.0-88
├── cluster-agent-operator-openshift-1.15-or-less.yaml
├── cluster-agent-operator-openshift.yaml
├── cluster-agent.yaml
├── infraviz.yaml
├── infraviz-pod-security-policy.yaml
├── infraviz-security-context-constraint-openshift.yaml
├── README-alpine.md
└── docker
├── cluster-agent.zip
├── Dockerfile
├── LICENSE
└── start-appdynamics
└── helm-charts
├── Chart.yaml
├── README.md
├── crds
├── templates
└── values.yaml
cluster-agent
├── cluster-agent-operator.yaml
├── appdynamics-operator-rhel-linux-amd64-21.12.0-88
├── cluster-agent-operator-openshift-1.15-or-less.yaml
├── cluster-agent-operator-openshift.yaml
├── cluster-agent.yaml
├── infraviz.yaml
├── infraviz-pod-security-policy.yaml
├── infraviz-security-context-constraint-openshift.yaml
├── README-rhel.md
└── docker
├── cluster-agent.zip
├── Dockerfile-rhel
├── LICENSE
└── start-appdynamics
└── helm-charts
├── Chart.yaml
├── README.md
├── crds
├── templates
└── values.yaml
Build the Custom Cluster Agent Image
Change directories into the
docker
directory:$ cd docker
CODEBuild and tag a
docker
image using this syntax:$ docker build -t <registryname>/<accountname>/cluster-agent:<Agent-version> --build-arg version=<alpine-version> .
CODE$ docker build -t <registryname>/<accountname>/cluster-agent:<Agent-version> -f Dockerfile-rhel .
CODETo use a specific Alpine Image version, specify the version using
--build-arg version=<alpine-version>
.If you do not specify an image version, then the build command takes the latest Alpine image version automatically.
For example, to build and tag the image version 21.12.0 using the latest alpine version on Docker Hub registry for the account namejohndoe:
$ docker build -t docker.io/johndoe/cluster-agent:21.12.0 .
CODE$ docker build -t docker.io/johndoe/cluster-agent:21.12.0 -f Dockerfile-rhel .
CODEWhen the build is successful, verify that the image appears in your local Docker repository.
Push the image:
$ docker push <registryname>/<accountname>/cluster-agent:<Agent-version>
BASHFor example, pushing the image version 21.12.0 to Docker Hub registry for the account name Johndoe
:
$ docker push docker.io/johndoe/cluster-agent:21.12.0
BASH
Use Pre-Built Cluster Agent Image
You can also use a pre-built Alpine-based Cluster Agent or Rhel-based Cluster Agent to an internal registry.
Alpine Cluster Agent Image
You can use the pre-built Alpine-based Cluster Agent image from the Docker Hub account.
Log in to your Docker Hub account:
$ docker login docker.io -u <your-username> -p <your-password>
CODEPull the image:
$ docker pull docker.io/appdynamics/cluster-agent:<Agent-version>
CODEFor example, to pull the Alpine based cluster agent image version 21.12.0:
$ docker pull docker.io/appdynamics/cluster-agent:21.12.0
CODE
To push this image to internal registry or accounts:
Rename the image:
$ docker tag docker.io/appdynamics/cluster-agent:<Agent-version> <registryname>/<accountname>/cluster-agent:<Agent-version>
CODEFor example:
$ docker tag docker.io/appdynamics/cluster-agent:21.12.0 docker.io/johndoe/cluster-agent:21.12.0
CODEPush the image:
$ docker push <registryname>/<accountname>/cluster-agent:<Agent-version>
CODEFor example, to push the image version 21.12.0 to Docker Hub registry for the account name Johndoe:
$ docker push docker.io/johndoe/cluster-agent:21.12.0
CODE
Rhel Cluster Agent Image
Alternatively, you can use the pre-built Rhel based Cluster Agent Image from the Redhat Container Registry account.
To use Redhat-based Cluster Agent, you may need to adjust your firewall settings as suggested by Redhat. Hence, you need to enable outbound connections to the following hostnames:
- cdn.quay.io
- cdn01.quay.io
- cdn02.quay.io
- cdn03.quay.io
Log in to Red Hat Registry using your Customer Portal credentials:
$ docker login registry.connect.redhat.com -u <your-username> -p <your-password>
CODEPull the image:
$ docker pull registry.connect.redhat.com/appdynamics/cluster-agent:<Agent-version>
CODEFor example, to pull the Rhel based Cluster Agent version 21.12.0:
$ docker pull registry.connect.redhat.com/appdynamics/cluster-agent:21.12.0
CODE
You can now use the Cluster Agent image.
To push this image to internal registry, or to other accounts:
Rename the image:
$ docker tag registry.connect.redhat.com/appdynamics/cluster-agent:<Agent-version> <registryname>/<accountname>/cluster-agent:<Agent-version>
CODEFor example:
$ docker tag registry.connect.redhat.com/appdynamics/cluster-agent:21.12.0 scan.connect.redhat.com/johndoe/cluster-agent:21.12.0
CODEPush the image:
$ docker push <registryname>/<accountname>/cluster-agent:<Agent-version>
CODEFor example, to push the image version 21.12.0 to Redhat Registry for account name
johndoe
:$ docker push scan.connect.redhat.com/johndoe/cluster-agent:21.12.0
CODE
Configure the Image in Cluster Agent YAML Specification
Make sure to reference the image in the cluster-agent.yaml
spec:
apiVersion: cluster.appdynamics.com/v1alpha1
kind: Clusteragent
metadata:
name: k8s-cluster-agent
namespace: appdynamics
spec:
controllerUrl: "http://<account>.saas.appdynamics.com"
account: "<account-name>"
appName: "Cluster1"
image: <registryname>/<username>/cluster-agent:<Agent-version>
For assistance, contact Customer Support.