Install the Scale Agent Plugin Using a Docker Image
Halyard local config
Warning
The Scale Agent plugin extends Clouddriver. When Halyard adds a plugin to a Spinnaker installation, it adds the plugin repository information to each service. This means that when you restart Spinnaker, each service restarts, downloads the plugin, and checks if an extension exists for that service. Each service restarting is not ideal for large Spinnaker installations due to service restart times. To avoid each service restarting and downloading the plugin, configure the plugin in Clouddriver’s local profile.Create a custom service setting that mounts an empty volume inside Clouddriver for the plugin image. Add the following to your
.hal/default/service-settings/clouddriver.yml
file:kubernetes: volumes: - id: kubesvc-plugin-vol type: emptyDir mountPath: /opt/clouddriver/lib/plugins
Define an init container for the plugin. In the
deploymentConfigurations.name.deploymentEnvironment.initContainers
section of your.hal/config
, add the following:spin-cloudriver: - name: kubesvc-plugin image: docker.io/armory/kubesvc-plugin:<version> volumeMounts: - mountPath: /opt/plugin/target name: kubesvc-plugin-vol
Be sure to use the plugin version compatible with your Spinnaker version.
Add the plugin to your
clouddriver-local.yml
.spinnaker: extensibility: plugins: Armory.Kubesvc: enabled: true extensions: armory.kubesvc: enabled: true pluginsRootPath: /opt/clouddriver/lib/plugins kubesvc: cluster: kubernetes kubernetes: enabled: true # enable Clouddriver Account Management if you are using Spinnaker 1.28+ account: storage: enabled: true
Apply your changes by running
hal deploy apply
.
Validate plugin installation
Confirm the plugin Docker image exists locally.
docker images | grep kubesvc
Output is similar to:
armory/kubesvc-plugin 0.11.32
Find the name of the new Clouddriver pod.
kubectl -n spinnaker get pods
Confirm the Clouddriver service is using the Docker image.
kubectl -n spinnaker describe pod <clouddriver-pod-name> | grep Image:
Output is similar to:
Image: docker.io/armory/kubesvc-plugin:0.11.32
View the Clouddriver log to verify that the plugin has started.
kubectl -n spinnaker logs deployments/spin-clouddriver | grep "Plugin"
Output is similar to:
org.pf4j.AbstractPluginManager : Plugin 'Armory.Kubesvc@0.11.32' resolved org.pf4j.AbstractPluginManager : Start plugin 'Armory.Kubesvc@0.11.32' io.armory.kubesvc.KubesvcPlugin : Starting Kubesvc plugin...
Armory Operator or Spinnaker Operator
You can find the Kustomize file plugin-container-patch.yml
in the spinnaker-patches-kustomize
repo.
Change the value for metadata.name
if your Armory CD service is called something other than “spinnaker”.
Then include the file under the patchesStrategicMerge
section of your kustomization file.
patchesStrategicMerge:
- <path>/plugin-container-patch.yml
Apply your changes.
Feedback
Was this page helpful?
Thank you for letting us know!
Sorry to hear that. Please tell us how we can improve.
Last modified March 3, 2023: (2d069084)