Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug: properties.count is missing when creating auto scaling agent pool #3220

Closed
b1zzu opened this issue Aug 31, 2023 · 4 comments
Closed

Bug: properties.count is missing when creating auto scaling agent pool #3220

b1zzu opened this issue Aug 31, 2023 · 4 comments
Assignees
Labels
bug 🪲 Something isn't working

Comments

@b1zzu
Copy link

b1zzu commented Aug 31, 2023

Version of Azure Service Operator
mcr.microsoft.com/k8s/azureserviceoperator:v2.2.0

Describe the bug
I'm trying to create the following managed cluster agent pool:

apiVersion: containerservice.azure.com/v1api20230201
kind: ManagedClustersAgentPool
metadata:
  name: highmem
  namespace: default
  annotations:
    serviceoperator.azure.com/reconcile-policy: detach-on-delete
spec:
  azureName: highmem0
  owner:
    name: my-cluster
  mode: User
  enableAutoScaling: true
  minCount: 3
  maxCount: 21
  upgradeSettings:
    maxSurge: 33%
  vmSize: Standard_E2s_v4

but the reconciliation loops fails with the following error:

--------------------------------------------------------------------------------                                                                                                  
RESPONSE 400: 400 Bad Request                                                                                                                                                     
ERROR CODE: InvalidParameter                                                                                                                                                      
--------------------------------------------------------------------------------                                                                                                  
{                                                                                                                                                                                 
  "code": "InvalidParameter",                                                                                                                                                     
  "details": null,                                                                                                                                                                
  "message": "Required parameter properties.count is missing (null).",                                                                                                            
  "subcode": "",                                                                                                                                                                  
  "target": "properties.count"                                                                                                                                                    
}                                                                                                                                                                                 
-------------------------------------------------------------------------------- 

on PUT https://management.azure.com/subscriptions/my-sub-id/resourceGroups/my-group/providers/Microsoft.ContainerService/managedClusters/my-cluster/agentPools/highmem0

Workaround

Add count: 1 to the spec, it will be ignored because the auto-scaling settings will overwrite it but at least will fix the issue.

@matthchr
Copy link
Member

Sorry for the slow response on this @b1zzu. This looks like a bug to me as well but I am confirming with the AKS team.

@matthchr
Copy link
Member

Confirmed that this is a bug/unintended behavior in the AKS API.

In the meantime, your workaround will work. The AKS team will fix this behavior in a future release, but I don't have an ETA currently.

I'll leave this item open to track this.

@theunrepentantgeek theunrepentantgeek added this to the v2.5.0 milestone Nov 14, 2023
@matthchr matthchr added the blocked 🚧 Blocked by external factors label Nov 28, 2023
@theunrepentantgeek theunrepentantgeek modified the milestones: v2.5.0, v2.6.0, v2.7.0 Dec 11, 2023
@matthchr matthchr removed this from the v2.6.0 milestone Feb 22, 2024
@matthchr
Copy link
Member

matthchr commented Aug 5, 2024

I think that this behavior has been solved in the upstream AKS API. I will confirm when it is being released as it may not be released yet.

@matthchr
Copy link
Member

matthchr commented Aug 7, 2024

Fix for this should be rolling out in a few weeks across the whole of AKS (so will improve this experience in ASO but also ARM templates, Terraform, etc).

Going to go ahead and close this given that is happening and there's nothing for us to do on ASO side.

@matthchr matthchr closed this as completed Aug 7, 2024
@github-project-automation github-project-automation bot moved this from Backlog to Recently Completed in Azure Service Operator Roadmap Aug 7, 2024
@matthchr matthchr removed known-issue blocked 🚧 Blocked by external factors labels Aug 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🪲 Something isn't working
Projects
Development

No branches or pull requests

3 participants