aws-toolkit-azure-devops
aws-toolkit-azure-devops copied to clipboard
Fix for installing aws.lambda.tools along side nuget.config with priv…
…ate feed.
This change will always allow aws.lambda.tools to be installed in the buildpipeline regardless of the presence of a private feed in the nuget config.
Description
I changed the installation command from dotnet install aws.lambda.tools to dotnet install -g --ignore-failed-sourced --add-source https://api.nuget.org/v3/index.json --version '*'
Motivation
The installation will fail if you have a nuget.config file with a private feed in it. See tickets: https://github.com/dotnet/sdk/issues/9555
To replicate the issue, try to build any lambda project, with a nuget.config file with a private feed listed.
Related Issue(s), If Filed
https://github.com/dotnet/sdk/issues/9555
Related to tickets where the user is unable to use the pipeline https://github.com/aws/aws-toolkit-azure-devops/issues/354 https://github.com/aws/aws-toolkit-azure-devops/issues/350
There is the possibility to add a version number to the aws.lambda.tools installation command, so we can force it on 4.0.0, and avoid it loading a older version from a private feed. But by selecting version '*' we keep the same version selection logic as today, and don't change that part.
Testing
I have replicated the installation process on my own PC, by simply running the dotnet install command along side a nuget.config package. I don't have access to a private devops setup. So I have not been able to verify the setup live. Can someone help test this on a devops pipeline before merging?
Checklist
- [X] I have read the README document
- [X] I have read the CONTRIBUTING document
- [X] My code follows the code style of this project
- [-] I have added tests to cover my changes
- [X] A short description of the change has been added to the changelog using the script
npm run newChange
License
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.
Codecov Report
Merging #355 into master will not change coverage. The diff coverage is
100.00%.
@@ Coverage Diff @@
## master #355 +/- ##
=======================================
Coverage 52.07% 52.07%
=======================================
Files 53 53
Lines 2241 2241
Branches 373 373
=======================================
Hits 1167 1167
Misses 1072 1072
Partials 2 2
| Impacted Files | Coverage Δ | |
|---|---|---|
| Tasks/Common/dotNetCliWrapper.ts | 65.57% <100.00%> (ø) |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact),ø = not affected,? = missing dataPowered by Codecov. Last update 589a223...d7378de. Read the comment docs.