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

NetworkPolicyNotSupported error when supplying NetworkPolicy in kubernetesClustersClient.CreateOrUpdate method #2176

Closed
lfshr opened this issue Jul 3, 2018 · 8 comments
Labels
customer-reported Issues that are reported by GitHub users external to the Azure organization. Mgmt This issue is related to a management-plane library. needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team

Comments

@lfshr
Copy link

lfshr commented Jul 3, 2018

NetworkPolicyNotSupported is being thrown when kubernetesClustersClient.CreateOrUpdate is being called with NetworkPolicy specified.

NetworkPolicy := containerservice.NetworkPolicy("calico")

parameters := containerservice.ManagedCluster{
	Name:     &name,
	Location: &location,
	ManagedClusterProperties: &containerservice.ManagedClusterProperties{
		AgentPoolProfiles:       &agentProfiles,
		DNSPrefix:               &dnsPrefix,
		KubernetesVersion:       &kubernetesVersion,
		LinuxProfile:            &linuxProfile,
		ServicePrincipalProfile: servicePrincipalProfile,
		NetworkProfile:          networkProfile,
		NetworkPolicy:          networkPolicy,
	},
}

ctx := client.StopContext
future, err := kubernetesClustersClient.CreateOrUpdate(ctx, resGroup, name, parameters)
Status=400 Code="NetworkPolicyNotSupported" Message="NetworkPolicy is not supported" Target="networkProfile"
@tombuildsstuff
Copy link
Contributor

@lfshr I'm unfamiliar with Network Policies, but are they perhaps only supported on a given version of Kubernetes?

@lfshr
Copy link
Author

lfshr commented Jul 25, 2018

@tombuildsstuff none of the documentation indicated such. It may only be a thing on kubenet.

@vladbarosan
Copy link

@lfshr is this related ? Azure/AKS#435

@vladbarosan
Copy link

@lfshr is this issue resolved by #2178 resolution ?

@lfshr
Copy link
Author

lfshr commented Oct 5, 2018

@vladbarosan this issue is unrelated. It's also low priority as there is only one network policy at the minute (calico), which is default when not specified. Same goes for #2177

@tzhanl tzhanl added the Mgmt This issue is related to a management-plane library. label Nov 18, 2020
@RickWinter RickWinter added this to the Backlog milestone Jul 12, 2021
@RickWinter RickWinter added customer-reported Issues that are reported by GitHub users external to the Azure organization. and removed backlog labels Jul 12, 2021
@RickWinter RickWinter removed the P1 label Jul 22, 2021
@lirenhe
Copy link
Member

lirenhe commented Sep 10, 2021

@lfshr, as this issue was reported a couple of years ago, does this issue still occur?

@RickWinter RickWinter added needs-author-feedback Workflow: More information is needed from author to address the issue. and removed customer-response-expected labels Sep 17, 2021
@lfshr
Copy link
Author

lfshr commented Sep 24, 2021

@lfshr, as this issue was reported a couple of years ago, does this issue still occur?

I don't really have my environment set up to test. As it was a few years ago, and AKS now supports Kubenet with Calico, I'd assume this could be closed.

@ghost ghost added needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team and removed needs-author-feedback Workflow: More information is needed from author to address the issue. labels Sep 24, 2021
@lirenhe
Copy link
Member

lirenhe commented Sep 28, 2021

Thanks @lfshr. Close this item.

@lirenhe lirenhe closed this as completed Sep 28, 2021
@RickWinter RickWinter modified the milestones: Backlog, [2021] October Dec 29, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Apr 11, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
customer-reported Issues that are reported by GitHub users external to the Azure organization. Mgmt This issue is related to a management-plane library. needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team
Projects
None yet
Development

No branches or pull requests

7 participants