Hello people, I'm running into this weird issue wi...
# general
p
Hello people, I'm running into this weird issue with AKS. The nodepool gets re-created any time I do
pulumi up
, which now makes the deployment take so long. This is what my cluster looks like:
Copy code
const k8sCluster = new azure.containerservice.KubernetesCluster(config.clusterName, {
    resourceGroupName: resourceGroup.name,
    location: resourceGroup.location,   
    name: config.clusterName,
    agentPoolProfiles: [{
        name: "nodepool1",
        count: config.nodeCount,
        vmSize: config.nodeSize,
        osType: "Linux"
    }],
    dnsPrefix: `${pulumi.getStack()}-kube`,
    servicePrincipal: {
        clientId: app.applicationId,
        clientSecret: spPassword
    },
    tags: {
        environment: config.env,
    },
}, { dependsOn: [app, adSpPassword] });
And here is
pulumi up
in action:
t
AKS API has changed, you should adjust your code to use
defaultNodePool
instead. See https://github.com/pulumi/examples/blob/master/azure-ts-aks-mean/cluster.ts#L22
p
Thanks! I tried doing that, it errors about the
type
Copy code
defaultNodePool: {
   name: "nodepool",
   nodeCount: config.nodeCount,
   vmSize: config.nodeSize,
   type: "Linux"
 },
I have found available options for the "Type"
t
I think you can just omit it
p
Yeah, thanks. I'll switch to
defaultNodePool
again
Update: using
defaultNodePool
fixed it. thanks @tall-librarian-49374
👍 2