Skip to content

Commit

Permalink
fix: update client API call to use StatefulSet instead of Deployment
Browse files Browse the repository at this point in the history
Co-authored-by: Dominik Augustin <yeahservice@users.noreply.github.com>
Signed-off-by: Matthis Holleville <matthish29@gmail.com>
  • Loading branch information
matthisholleville and yeahservice committed Mar 31, 2023
1 parent 3603872 commit 4916fef
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/analyzer/hpaAnalyzer.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ func AnalyzeHpa(ctx context.Context, config *AnalysisConfiguration, client *kube
scaleTargetRefNotFound = true
}
case "StatefulSet":
_, err := client.GetClient().AppsV1().Deployments(config.Namespace).Get(ctx, scaleTargetRef.Name, metav1.GetOptions{})
_, err := client.GetClient().AppsV1().StatefulSets(config.Namespace).Get(ctx, scaleTargetRef.Name, metav1.GetOptions{})
if err != nil {
scaleTargetRefNotFound = true
}
Expand Down

0 comments on commit 4916fef

Please sign in to comment.