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

Use pre-installed Az PowerShell module rather than downloading from PSGallery #1051

Closed
scbedd opened this issue Sep 28, 2020 · 5 comments
Closed
Assignees
Labels
Central-EngSys This issue is owned by the Engineering System team. EngSys This issue is impacting the engineering system.

Comments

@scbedd
Copy link
Member

scbedd commented Sep 28, 2020

Last night we saw the following error.

Now, the pshell installer module already retries an download/install 3 times if it hits an exception. The issue here is that the repository threw a false-negative, which ended up crashing our pipeline.

Whether wrapping the entire script in a retry-loop is the solution, I'll leave up to the implementer.

@scbedd scbedd added the EngSys This issue is impacting the engineering system. label Sep 28, 2020
@weshaggard
Copy link
Member

This goes a little larger then smok-tests I've see it fail for normal live test runs as well. We need to come up with some way to reduce this error path when powershell gallery isn't responsive.

@kurtzeborn kurtzeborn added the Central-EngSys This issue is owned by the Engineering System team. label Sep 29, 2020
@kurtzeborn kurtzeborn changed the title Smoke-Test Runs - Reduce Installed PShell Module FootPrint All Test Runs - Reduce Installed PShell Module FootPrint Sep 29, 2020
@weshaggard
Copy link
Member

Looks like at least hosted image already includes these PS modules (https://github.com/actions/virtual-environments/blob/main/images/win/Windows2019-Readme.md#azure-powershell-modules) and we should try to use those instead of always doing a force install. From a quick look it seems windows and linux have 4.7 and mac has 4.6.1 and as long as those versions are enough we should just use those instead of install anything.

@weshaggard
Copy link
Member

@heaths do you remember why we do a force install? (https://github.com/Azure/azure-sdk-tools/blob/master/eng/common/TestResources/setup-az-modules.yml#L24) as opposed to using the versions on the machine?

@heaths
Copy link
Member

heaths commented Oct 9, 2020

The force install has nothing to do with overriding what's installed. It's because you're prompted, by default, unless you pass -Force. If you want to use what's there, first do a get-module -list <whatever> to see if it's installed and, if not, you can install it. When I wrote these, I didn't realize the modules were on the image.

@weshaggard weshaggard changed the title All Test Runs - Reduce Installed PShell Module FootPrint Use pre-installed Az PowerShell module rather than downloading from PSGallery Oct 16, 2020
@mikeharder mikeharder assigned mikeharder and unassigned danieljurek Oct 21, 2020
@mikeharder
Copy link
Member

Fixed by #1137

sima-zhu pushed a commit to sima-zhu/azure-sdk-tools that referenced this issue Dec 3, 2020
…EOWNERS emails (Azure#1051)

* Enable alerts: move ci.yml, add CODEOWNERS
* Move ci.yml to sdk/ to align better with repo layout and take advantage of the SDK owners
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Central-EngSys This issue is owned by the Engineering System team. EngSys This issue is impacting the engineering system.
Projects
None yet
Development

No branches or pull requests

6 participants