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

[App Service] BREAKING CHANGE: az webapp list-runtimes: Use new stacks APIs #21057

Merged
merged 48 commits into from
Feb 11, 2022

Conversation

StrawnSC
Copy link
Contributor

@StrawnSC StrawnSC commented Jan 20, 2022

Description

Changes the commands az webapp up, az webapp create and az webapp list-runtimes to use web app stacks from the API rather than a hardcoded list.
Also does the same for az functionapp create and creates a new command az functionapp list-runtimes. Note that the command az functionapp list-runtimes has more verbose output that it's webapp equivalent because function app stacks availability depends on the functions version (v3, v4, etc).

Unrelated to the other changes, this also uses the : delimiter for az webapp list-runtimes instead of | to avoid PowerShell issues.

Currently*, the webapp stacks that will no longer be supported are as follows:

  • windows: "node|10.6", "node|10.10", "node|10.14", "java|7|Tomcat|7.0", "java|7|Tomcat|8.5", "java|7|Tomcat|9.0", "java|7|Java SE|8", "DOTNETCORE|2.1"
  • linux: "DOTNETCORE|2.1", "NODE|10.1", "NODE|10.6", "NODE|10.14", "JBOSSEAP|7.3-java8", "JBOSSEAP|7.3-java11"

*These lists will change over time since the values will be set by the API.

Example Usage
az webapp list-runtimes output using no arguments:
Screen Shot 2022-02-08 at 8 38 35 PM

az webapp list-runtimes output using --os argument:
Screen Shot 2022-02-08 at 8 40 00 PM

az functionapp list-runtimes output without an --os argument:
Screen Shot 2022-02-01 at 11 19 55 AM

az functionapp list-runtimes output with an --os argument:
Screen Shot 2022-02-01 at 11 20 35 AM

Testing Guide

azdev test --live test_webapp_up_commands test_webapp_commands
azdev test --live test_functionapp_commands

History Notes

[App Service] BREAKING CHANGE: az webapp up : Change supported runtimes
[App Service] BREAKING CHANGE: az webapp create : Change supported runtimes
[App Service] BREAKING CHANGE: az webapp list-runtimes : Add --os/--os-type argument, change runtimes, change default behavior to return both linux and windows stacks, and deprecate --linux argument
[App Service] BREAKING CHANGE: az functionapp create : Take runtime names and versions from API instead of hardcoded list
[App Service] az functionapp list-runtimes : Add new command to show function app runtimes, versions, and compatible functions versions


This checklist is used to make sure that common guidelines for a pull request are followed.

@yonzhan
Copy link
Collaborator

yonzhan commented Jan 20, 2022

App Service

@panchagnula
Copy link
Contributor

@StrawnSC & @calvinsID ,Regarding DIR path & file paths handling - whatever we do should work across windows/ Linux/ all OS file systems. Expecting the path to be a certain format is incorrect. Whatever fixes you do here ensure - doesn't cause any regressions - I recommend keeping this change targeted to Stacks API only & use another PR,, for unrelated changes/ fixes.

@calvinsID
Copy link
Contributor

calvinsID commented Feb 2, 2022

Thanks so much for doing this, glad to see we're off the hardcoded lists :D

Np! By the way, this may cause some issues with the command az webapp deployment github-actions add, although it seems the command was already broken: #20808

Thanks for making the fix for removing the "/". If there are further fixes needed for gh actions (especially if the workflow file needs any changes) I'm thinking we can do those in a later PR

Edit: Or we can do all the changes in later PR as well

@StrawnSC
Copy link
Contributor Author

StrawnSC commented Feb 2, 2022

@panchagnula here's the output without an --os argument. It's cut off, but lower down there's a section for windows stacks. It's essentially the same as the webapps command in how it shows the stacks by OS

Screen Shot 2022-02-01 at 11 19 55 AM

@zhoxing-ms
Copy link
Contributor

I'm not sure why the CI tests are failing on the "Build Docker Image" check. Do you know what's going on there?

@StrawnSC This is a known issue jmespath/jmespath.terminal#19 related to jmespath-terminal, we will plan to drop the dependence on it.

@zhoxing-ms
Copy link
Contributor

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 2 pipeline(s).

Copy link
Contributor

@panchagnula panchagnula left a comment

Choose a reason for hiding this comment

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

LGTM

@StrawnSC
Copy link
Contributor Author

StrawnSC commented Feb 9, 2022

@zhoxing-ms thanks for the help with the CI issues. Was the credential scan check changed recently? It was passing last week on the test recordings, but now it appears to be failing

@zhoxing-ms
Copy link
Contributor

@StrawnSC This is a problem caused by credscan package Microsoft.Security.CredScan upgrade. We have submitted a PR #21230 to pin it

@zhoxing-ms
Copy link
Contributor

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 2 pipeline(s).

@StrawnSC
Copy link
Contributor Author

@zhoxing-ms any chance we could get this merged soon? @panchagnula has another big upcoming change that's blocked until this is in dev

@zhoxing-ms zhoxing-ms changed the title [App Service] BREAKING CHANGE : Use new web app and function app stacks APIs [App Service] BREAKING CHANGE: Use new web app and function app stacks APIs Feb 11, 2022
@panchagnula panchagnula changed the title [App Service] BREAKING CHANGE: Use new web app and function app stacks APIs [App Service] BREAKING CHANGE: az webapp list-runtimes : use new stacks APIs Feb 11, 2022
@zhoxing-ms zhoxing-ms changed the title [App Service] BREAKING CHANGE: az webapp list-runtimes : use new stacks APIs [App Service] BREAKING CHANGE: az webapp list-runtimes: Use new stacks APIs Feb 11, 2022
@zhoxing-ms zhoxing-ms merged commit 45ef11f into Azure:dev Feb 11, 2022
@StrawnSC StrawnSC deleted the unhardcode_webapp_list-runtimes branch February 11, 2022 06:36
@calvinsID calvinsID linked an issue Feb 28, 2022 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

webapp: Hook up to the new available stack API with ANT92
6 participants