Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,6 @@ jobs:
filePath: build_scripts\windows\scripts\test_zip_installation.ps1

- job: BuildDockerImageAlpine
continueOnError: true
displayName: Build Docker Image Alpine
strategy:
matrix:
Expand Down Expand Up @@ -358,7 +357,6 @@ jobs:
ArtifactName: $(artifactName)

- job: TestDockerImageAlpine
continueOnError: true
displayName: Test Docker Image Alpine
dependsOn:
- BuildDockerImageAlpine
Expand Down
8 changes: 8 additions & 0 deletions src/azure-cli/azure/cli/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,12 @@

logger = get_logger(__name__)

ALPINE_WARNING_MESSAGE = (
"Azure CLI 2.63.0 is the last version available on Alpine and will not receive updates. "
"Consider migrating to the Azure Linux based image for Azure CLI. "
"For more information: https://go.microsoft.com/fwlink/?linkid=2282203"
)
Copy link
Contributor

@bebound bebound Aug 1, 2024

Choose a reason for hiding this comment

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

The GitHub actions users will see this warning. We'd better to add the instruction to hide the warning.
azure/cli actions also need to migrate to Azure Linux based image in the future.
@MoChilia

Copy link
Member Author

Choose a reason for hiding this comment

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

az config set core.only_show_errors=true can control this message.

Copy link
Member

Choose a reason for hiding this comment

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

It's great to use az config to hide this warning message, but it may also hide other warnings. I will first migrate azure/cli action to use Mariner-based image to avoid this warning and ensure the latest azure-cli is available in azure/cli action. Later we may migrate to Azure Linux based image once it's ready.

Copy link
Member Author

Choose a reason for hiding this comment

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

It's great to use az config to hide this warning message, but it may also hide other warnings.

I think this is acceptable. I don't want to spend too much effort on this warning message as Alpine-based images will no longer be released/maintained.

Copy link
Contributor

Choose a reason for hiding this comment

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

@jiasli, isn't it just Alpine and not Alpine 10?

Copy link
Contributor

Choose a reason for hiding this comment

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

There is no “alpine 10”.

PS: There is Alpine 3.10. But we’re using 3.20 now. I think we can omit the version number in warning message.



def cli_main(cli, args):
return cli.invoke(args)
Expand Down Expand Up @@ -124,6 +130,8 @@ def cli_main(cli, args):
except Exception as ex: # pylint: disable=broad-except
logger.debug("Intercept survey prompt failed. %s", str(ex))

logger.warning(ALPINE_WARNING_MESSAGE)

telemetry.set_init_time_elapsed("{:.6f}".format(init_finish_time - start_time))
telemetry.set_invoke_time_elapsed("{:.6f}".format(invoke_finish_time - init_finish_time))
telemetry.conclude()