mirror of
https://github.com/k8sgpt-ai/k8sgpt.git
synced 2025-09-24 12:50:21 +00:00
feat: check if ScaleTargetRef is possible option
Signed-off-by: Matthis Holleville <matthish29@gmail.com>
This commit is contained in:
@@ -48,6 +48,8 @@ func AnalyzeHpa(ctx context.Context, config *AnalysisConfiguration, client *kube
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
scaleTargetRefNotFound = true
|
scaleTargetRefNotFound = true
|
||||||
}
|
}
|
||||||
|
default:
|
||||||
|
failures = append(failures, fmt.Sprintf("HorizontalPodAutoscaler uses %s as ScaleTargetRef which does not possible option.", scaleTargetRef.Kind))
|
||||||
}
|
}
|
||||||
|
|
||||||
if scaleTargetRefNotFound {
|
if scaleTargetRefNotFound {
|
||||||
|
Reference in New Issue
Block a user