Download PDF
Download page AppDynamics Operator Container Image.
AppDynamics Operator Container Image
This page describes how to build a custom AppDynamics Operator container image or use the pre-built images and store it to an internal registry.
This procedure is required when you:
- Require to build custom AppDynamics Operator container image
- Require to use the pre-built AppDynamics Operator Image on DockerHub or RedHat Registry, and store it in the internal registry.
Otherwise, by default Appdynamics Operator pod can directly pull and use the latest pre-built AppDynamics Operator Container Images on the AppDynamics DockerHub repository or AppDynamics RedHat registry.
Build the Custom AppDynamics Operator Image
The download packages from the AppDynamics 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 AppDynamics Operator 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 are:
cluster-agent
├── cluster-agent-operator.yaml
├── appdynamics-operator-alpine-linux-amd64-21.12.0-88
├── bin
├── appdynamics-operator
├── Dockerfile
├── LICENSE
└── scripts
├── ensure-user.sh
├── start-operator.sh
├── 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
└── 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
├── bin
├── appdynamics-operator
├── Dockerfile-rhel
├── LICENSE
└── scripts
├── ensure-user.sh
├── start-operator.sh
├── 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
└── helm-charts
├── Chart.yaml
├── README.md
├── crds
├── templates
└── values.yaml
Build the Custom AppDynamics Operator Image
Change directory to the Operator directory:
$ cd appdynamics-operator-alpine-linux-amd64-21.12.0-88/
CODEBuild and tag a
docker
image using this syntax:$ docker build -t <registryname>/<accountname>/cluster-agent-operator:<Operator_Version> .
CODE$ docker build -t <registryname>/<accountname>/cluster-agent-operator:<Operator_Version> -f Dockerfile-rhel .
CODEFor example, to build and tag the image version 21.12.0 using the latest alpine version on Docker Hub registry for the account name
johndoe:
$ docker build -t docker.io/johndoe/cluster-agent-operator:21.12.0 .
CODE$ docker build -t docker.io/johndoe/cluster-agent-operator:21.12.0 -f Dockerfile-rhel .
CODEPush the image:
$ docker push <registryname>/<accountname>/cluster-agent-operator:<Operator_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-operator:21.12.0
BASH
Use Pre-Built AppDynamics Operator Image
You can also use a pre-built Alpine-based or Rhel-based AppDynamics Operator images to an internal registry.
Alpine Cluster Agent Image
You can use the pre-built Alpine-based AppDynamics Operator image from the AppDynamics DockerHub 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-operator:<Operator_Version>
CODEFor example, to pull the Alpine based cluster agent image version 21.12.0:
$ docker pull docker.io/appdynamics/cluster-agent-operator:21.12.0
CODE
To push this image to internal registry or accounts:
Rename the image:
$ docker tag docker.io/appdynamics/cluster-agent-operator:<Operator_Version> <registryname>/<accountname>/cluster-agent-operator:<Operator_Version>
CODEFor example:
$ docker tag docker.io/appdynamics/cluster-agent-operator:21.12.0 docker.io/johndoe/cluster-agent-operator:21.12.0
CODEPush the image:
$ docker push <registryname>/<accountname>/cluster-agent-operator:<Operator_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-operator:21.12.0
CODE
Rhel Cluster Agent Image
Alternatively, you can use the pre-built Rhel based AppDynamics Operator Image from the Appdynamics Redhat Container Registry account.
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-operator:<Operator_Version>
CODEFor example, to pull the Rhel based AppDynamics Operator version 21.12.0:
$ docker pull registry.connect.redhat.com/appdynamics/cluster-agent-operator: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-operator:<Operator_Version> <registryname>/<accountname>/cluster-agent-operator:<Operator_Version>
CODEFor example:
$ docker tag registry.connect.redhat.com/appdynamics/cluster-agent-operator:21.12.0 scan.connect.redhat.com/johndoe/cluster-agent-operator:21.12.0
CODEPush the image:
$ docker push <registryname>/<accountname>/cluster-agent-operator:<Operator_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-operator:21.12.0
CODE
Configure the Image in AppDynamics Operator YAML Specification
Make sure to reference the image in the cluster-agent-operator.yaml
or cluster-agent-operator-
openshift.yaml spec:
apiVersion: cluster.appdynamics.com/v1alpha1
apiversion: apps/v1
kind: Deployment
metadata:
name: appdynamics-operator
namespace: appdynamics
spec:
replicas: 1
selector
matchLabels:
name: appdynamics-operator
template:
metadata:
labels:
name: appdynamics-operator
spec:
serviceAccountName: appdynamics-operator
containers:
- name: appdynamics-operator
image: <registryname>/<username>/cluster-agent-operator:<Operator_Version>
ports:
-containerPort: 60000
name: metrics
command:
-appdynamics-operator
imagePullPolicy: Always
resources:
limits:
cpu: 200m
memory: 128N1
requests:
cpu: 100m
memory: 64M1
env:
-name: WATCH NAMESPACE
valueFrom:
fieldRef:
fieldPath: metadata, namespace
-name: POD_NAME
valueFrom:
fieldRef:
fieldPath:-metadata.name
-name: OPERATOR_NAME
value: appoynamics-operator
For assistance, contact AppDynamics Support.