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

install latest version of mgmt package only. #25251

Open
ozbillwang opened this issue Jan 27, 2023 · 1 comment
Open

install latest version of mgmt package only. #25251

ozbillwang opened this issue Jan 27, 2023 · 1 comment
Assignees
Labels
Auto-Assign Auto assign by bot Azure CLI Team The command of the issue is owned by Azure CLI team customer-reported Issues that are reported by GitHub users external to the Azure organization. feature-request Installation
Milestone

Comments

@ozbillwang
Copy link

ozbillwang commented Jan 27, 2023

I found the current installation for Azure-CLI could be huge space used in #19591

When more versions to be added later, the package size could be bigger.

Related command

$ cd <Azure_CLI_package>/azure-cli/2.44.1/libexec/lib/python3.10/site-packages/azure
$ du -sk * |sort -n|tail -2
44368	cli
498384	mgmt

So mgmt takes most space for the package azure-cli

$ cd mgmt/network

$ ls -l 
...
drwxr-xr-x  11 bill  admin     352 11 Jan 02:31 v2020_06_01
drwxr-xr-x  11 bill  admin     352 11 Jan 02:31 v2020_07_01
drwxr-xr-x  11 bill  admin     352 11 Jan 02:31 v2020_08_01
drwxr-xr-x  11 bill  admin     352 11 Jan 02:31 v2020_11_01
drwxr-xr-x  11 bill  admin     352 11 Jan 02:31 v2021_02_01
drwxr-xr-x  12 bill  admin     384 18 Jan 11:20 v2021_02_01_preview
drwxr-xr-x  12 bill  admin     384 18 Jan 11:20 v2022_01_01

$ ls -ld v* |wc -l
      33

So the packages are installed 33 times for all versions for mgmt.

It is only for normal installation, but it makes the size of docker image mcr.microsoft.com/azure-cli to huge (1.35GB)

mcr.microsoft.com/azure-cli        latest                 ba903d03e1cd   6 weeks ago      1.35GB

Are there any options or parameters I can use to only install the latest version in mgmt for production installation?

@ghost ghost added customer-reported Issues that are reported by GitHub users external to the Azure organization. Auto-Assign Auto assign by bot Installation labels Jan 27, 2023
@ghost ghost assigned jiasli Jan 27, 2023
@ghost ghost added this to the Backlog milestone Jan 27, 2023
@wangzelin007
Copy link
Member

@jiasli for awareness

@yonzhan yonzhan added feature-request Azure CLI Team The command of the issue is owned by Azure CLI team labels Jan 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Auto-Assign Auto assign by bot Azure CLI Team The command of the issue is owned by Azure CLI team customer-reported Issues that are reported by GitHub users external to the Azure organization. feature-request Installation
Projects
None yet
Development

No branches or pull requests

4 participants