I'm trying to setup Automated Canary Analysis for my application running in an On-Prem Kubernetes cluster using the steps here . We are using Prometheus for monitoring/metrics.
I'm faced with the following error in the Canary Analysis
stage when running the pipeline:
Either a resource type or a custom filter is required.
The issue is that the Resource Type
dropdown is not available on the Canary Analysis
form when adding the stage. Based on the screen shots in the Spinnaker how-to article, and in the article above, the Resource Type
dropdown should be there.
Any idea why is the Resource Type
not available on the Canary Analysis form? Am I missing some Halyard config?
Here is my Halyard config(with bash variables not shown):
hal config version edit --version 1.10.5
echo $MINIO_PWD | hal config storage s3 edit --endpoint http://minio-service.spinnaker.svc.cluster.local:9001/ --bucket data --access-key-id spinnaker-minio --secret-access-key
hal config storage edit --type s3
hal config canary enable
hal config canary prometheus enable
hal config canary prometheus account add $PROMETHEUS_ACCT --base-url http://$PROMETHEUS_URL:9090
hal config canary edit --show-all-configs-enabled false
hal config canary edit --default-metrics-store prometheus
hal config canary edit --default-metrics-account $PROMETHEUS_ACCT
hal config canary aws enable
echo $MINIO_PWD | hal config canary aws account add $AWS_CANARY_ACCT --bucket canary-data --access-key-id spinnaker-minio --endpoint http://minio-service.spinnaker.svc.cluster.local:9001/ --secret-access-key
hal config canary aws edit --s3-enabled=true
hal config canary edit --default-storage-account $AWS_CANARY_ACCT
hal config provider docker-registry enable
hal config provider docker-registry account add $DOCKER_REGISTRY_ACCOUNT --address $DOCKER_REGISTRY_ADDRESS
echo $DOCKER_HUB_PWD | hal config provider docker-registry account edit $DOCKER_REGISTRY_ACCOUNT --username $DOCKER_REGISTRY_ACCOUNT --address $DOCKER_REGISTRY_ADDRESS --add-repository $DOCKER_REGISTRY_REPOSITORY --password
hal config provider kubernetes enable
hal config provider kubernetes account delete k8s-account
hal config provider kubernetes account add k8s-account --context kubernetes-admin@kubernetes --docker-registries $DOCKER_REGISTRY_ACCOUNT --namespaces $K8S_NAMESPACES
hal config deploy edit --type distributed --account-name k8s-account
hal deploy apply
I was able to resolve this by adding a filter template in the metric of the canary config. The canary analysis task was able to run without error after adding this