-
Notifications
You must be signed in to change notification settings - Fork 3k
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
webapp: --ip-address accepts only cidr not ip4 #12010
Comments
Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @AzureAppServiceCLI @antcp |
@madsd I haven't tried to repro this but wanted to check with you if this was by design. Thanks! |
Hi @panchagnula, this was by design, but that could be changed :-) Perhaps something as simple as checking for '.' or ':' (to know if it is ipv4 or ipv6) and then add respectively /32 and /128. Would that make sense? |
Thanks @madsd - Hmm not sure what the reasoning was for this to be ByDesign since on Portal we do support Ipv4 and IpV6. |
@panchagnula the command does support both ipv4 and ipv6 today - but for both ipv4 and ipv6 you have to specify the subnet range - that is the /xx. So even if you just want a single IP, you need to specify /32. What is being asked here (as I read it), is that if you just want a single IP, we would automatically add the /32 or /128. |
@madsd True.
I would expect an ip address to be without /32 and a cidr of 1 ip to be with a /32. Anyway. when not specifying a subnet range on an ip, automatically adding a /32 would work fine. (or /128 for ip6) |
Created PR with a fix for it and a scenario test to capture it for future changes. @panchagnula could you review it. @onstwedder, thank you for reporting it. |
e.g. just tried the following:
az webapp config access-restriction add -g <resourcegroupname> -n <Webappname> --action Allow --description 'Outgoing ip' --ip-address 50.69.29.185 --rule-name 'webplan' --priority 505
which resulted in:
Operation returned an invalid status code 'Bad Request'
However when i tried this:
az webapp config access-restriction add -g <resourcegroupname> -n <Webappname> --action Allow --description 'Outgoing ip' --ip-address 50.69.29.185/32 --rule-name 'webplan' --priority 505
It worked correctly.
Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.
The text was updated successfully, but these errors were encountered: