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

Support AKS Virtual Nodes #2641

Merged
merged 3 commits into from
Jan 11, 2019
Merged

Support AKS Virtual Nodes #2641

merged 3 commits into from
Jan 11, 2019

Conversation

patst
Copy link
Contributor

@patst patst commented Jan 10, 2019

Support for the AKS virtual nodes feature currently in preview (https://docs.microsoft.com/en-us/azure/aks/virtual-nodes-cli ).

The corresponding issue is #2508

I updated the docs and created an integration test.

I could use some help getting the test running. At the moment it fails with:

TF_ACC=1 go test $(go list ./... |grep -v 'vendor') -v -run=TestAccAzureRMKubernetesCluster_addonProfileAciConnectorLinux -timeout 180m -ldflags="-X=github.com/terraform-providers/terraform-provider-azurerm/version.ProviderVersion=acc"
?       github.com/terraform-providers/terraform-provider-azurerm       [no test files]
=== RUN   TestAccAzureRMKubernetesCluster_addonProfileAciConnectorLinux
=== PAUSE TestAccAzureRMKubernetesCluster_addonProfileAciConnectorLinux
=== CONT  TestAccAzureRMKubernetesCluster_addonProfileAciConnectorLinux
--- FAIL: TestAccAzureRMKubernetesCluster_addonProfileAciConnectorLinux (800.89s)
    testing.go:538: Step 0 error: After applying this step and refreshing, the plan was not empty:
        
        DIFF:
        
        UPDATE: azurerm_subnet.test-aci
          delegation.#:                                "1" => "0"
          delegation.0.name:                           "aciDelegation" => ""
          delegation.0.service_delegation.#:           "1" => "0"
          delegation.0.service_delegation.0.actions.#: "1" => "0"
          delegation.0.service_delegation.0.actions.0: "Microsoft.Network/virtualNetworks/subnets/action" => ""
          delegation.0.service_delegation.0.name:      "Microsoft.ContainerInstance/containerGroups" => ""
        
        STATE:
        ...

Any ideas why? It seems the Virtual Node plugins modifies the subnet config.

Copy link
Member

@tombuildsstuff tombuildsstuff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hey @patst

Thanks for this PR :)

I've taken a look through and left some comments inline but this mostly LGTM - the test is failing because AKS is modifying the Subnet being passed in, so the configuration doesn't match the one provided by Azure - so if we can add in the missing configuration (and fix up the other minor comments) this should otherwise be good 👍

Thanks!

azurerm/resource_arm_kubernetes_cluster.go Show resolved Hide resolved
website/docs/r/kubernetes_cluster.html.markdown Outdated Show resolved Hide resolved
azurerm/resource_arm_kubernetes_cluster_test.go Outdated Show resolved Hide resolved
@patst
Copy link
Contributor Author

patst commented Jan 10, 2019

Thanks for the fast review and the hint how to fix the testcase!
It is working now and I think all review comments are addressed.

@ghost ghost removed the waiting-response label Jan 10, 2019
@katbyte katbyte changed the title #2508 Support AKS Virtual Nodes Support AKS Virtual Nodes Jan 11, 2019
Copy link
Member

@tombuildsstuff tombuildsstuff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hey @patst

Thanks for pushing those changes - this now LGTM 👍

Thanks!

@tombuildsstuff tombuildsstuff added this to the 1.21.0 milestone Jan 11, 2019
@tombuildsstuff
Copy link
Member

Ignoring an Azure API timeout error (on destroying the resource) - the tests pass:

screenshot 2019-01-11 at 13 12 27

@tombuildsstuff
Copy link
Member

Data Source tests pass too 👍

screenshot 2019-01-11 at 13 41 25

@tombuildsstuff tombuildsstuff merged commit dacb9dc into hashicorp:master Jan 11, 2019
tombuildsstuff added a commit that referenced this pull request Jan 11, 2019
@ghost
Copy link

ghost commented Mar 5, 2019

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 hashibot-feedback@hashicorp.com. Thanks!

@ghost ghost locked and limited conversation to collaborators Mar 5, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants