When I run the command az webapp list-runtimes I get the list shown at the list of the post as a result. However, When I try to create a new webapp through the azure web-interface I have the ability to choose a DotNet Core 2.2. runtime. That means that the cli cannot do the same things as the web-interface and makes the reproducibility of the environments difficult,
Command Name
az webapp list-runtimes
Errors:
Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.
az webapp list-runtimesInclude DotNet Core runtimes in the result list
Windows-10-10.0.18362-SP0
Python 3.6.6
Shell: powershell.exe
azure-cli 2.0.74
Current output of the command:
[
"aspnet|V4.7",
"aspnet|V3.5",
"node|0.6",
"node|0.8",
"node|0.10",
"node|0.12",
"node|4.8",
"node|6.5",
"node|6.9",
"node|6.12",
"node|7.10",
"node|8.1",
"node|8.4",
"node|8.5",
"node|8.9",
"node|8.10",
"node|8.11",
"node|10.0",
"node|10.6",
"node|10.14",
"node|10.15",
"php|5.6",
"php|7.0",
"php|7.1",
"php|7.2",
"php|7.3",
"python|2.7",
"python|3.6",
"java|1.7|Tomcat|7.0",
"java|1.7|Tomcat|8.0",
"java|1.7|Tomcat|8.5",
"java|1.7|Tomcat|9.0",
"java|1.7|Jetty|9.1",
"java|1.7|Jetty|9.3",
"java|1.7|Java SE|8",
"java|1.8|Tomcat|7.0",
"java|1.8|Tomcat|8.0",
"java|1.8|Tomcat|8.5",
"java|1.8|Tomcat|9.0",
"java|1.8|Jetty|9.1",
"java|1.8|Jetty|9.3",
"java|1.8|Java SE|8",
"java|11|Tomcat|7.0",
"java|11|Tomcat|8.0",
"java|11|Tomcat|8.5",
"java|11|Tomcat|9.0",
"java|11|Jetty|9.1",
"java|11|Jetty|9.3",
"java|11|Java SE|8"
]
Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @AzureAppServiceCLI @antcp
Confirmed with the API folks that this a known issue & will be fixed with our next deployment which is tentatively in late Nov 2019.
Is there also a way to tell which version is the latest for each stack type?
Looking at corresponding API I see that there is "isDefault" property, but it seems to not match latest versions of stacks (for example, for ruby isDefault is true for 2.4 and not 2.6).
Also sort order is sometimes oldest to newest version (for most of stacks), and sometimes vice versa (for python on Linux).
Hey folks -
Any updates on this ?
@btardif getting this on your radar since I don't own the API. Thanks!
is the problem just that the api doesn't return the values as part of the list? can we still pass in the right value if we know what it is? net.core|3.0 maybe?
For CLI right now API is the source of truth, for Linux this works,. this issue is for windows only and as long as you make sure deploy the 3.0 content - the runtime will do the right thing for windows.
Any idea when this release is scheduled for?
Is there currently a workaround to create an aspnetcore 2.2 app through the CLI or programatically another way? I need to create approx 10 and would rather not do it manually.
if this is windows app you can run the webapp create without the runtime parameter and then just deploy your code to the app. For windows the rumtime will take care of this - for linux & ASP.NET or core, we need to set the runtime. Also you can try https://docs.microsoft.com/en-us/cli/azure/webapp?view=azure-cli-latest#az-webapp-up
Is there currently a workaround to create an aspnetcore 2.2 app through the CLI or programatically another way? I need to create approx 10 and would rather not do it manually.
@danoliver1 - You can do it through ARM templates and then deploy the ARM template via az cli. You have to set the stack to "dotnetcore" using metadata on the site config property.
"siteConfig": {
"metadata": [
{
"name": "CURRENT_STACK",
"value": "dotnetcore"
}
]
}
Had the same problem as the OP.
To see the list of runtimes available for a Linux deployment run:
az webapp list-runtimes --linux
The --linux switch will give you all those available, including the dotnetcore ones
"DOTNETCORE|1.0",
"DOTNETCORE|1.1",
"DOTNETCORE|2.0",
"DOTNETCORE|2.1",
"DOTNETCORE|2.2",
"DOTNETCORE|3.0",
"DOTNETCORE|LTS",
"DOTNETCORE|Latest",
Most helpful comment
Had the same problem as the OP.
To see the list of runtimes available for a Linux deployment run:
az webapp list-runtimes --linuxThe
--linuxswitch will give you all those available, including the dotnetcore ones