-
Notifications
You must be signed in to change notification settings - Fork 4.1k
Set up CI with Azure Pipelines #8323
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
|
|
Collaborator
|
Can one of the admins verify this patch? |
Contributor
|
@azuresdkci add to whitelist |
…ds all modules and test projects. Now, Build target builds, and Test target just tests and does not build. Changed build to individually add projects to the solution to avoid issues on older versions of Windows. Skipped 6 tests, 4 that fail on both linux/macOS, and 2 that fail on macOS only.
… to install platyPS into PowerShell Core so we can actually use it.
…pendencyAnalyzer.cs to include System.Management.Automation as a framework assembly. Added logic to Program.cs to allow running help only. Retooled build.proj to have separate targets for StaticAnalysis and GenerateHelp. This allows them to run in parallel on CI. This also means they are no longer part of Build target.
…d output to go to artifacts/StaticAnalysis. Fixed BatchModelGenerator.csproj build issue.
…rk with StaticAnalysis Exceptions folder correctly. Fixed GenerateHelp.ps1 to only run for help folders as part of the build (instead of the src). Fixed bug with StaticAnalysis not creating the reports directory. Fixed StaticAnalysis not using the Exceptions directory in the same directory as the actual dll. Attempting to publish StaticAnalysis so it can run cross-plat.
…torage.DataMovement requiring Mono.Posix.NETStandard. Also, guaranteed results directories are created.
…s into build. Composed current pipeline ymls via templates. Added Mono.Posix.NETStandard.dll copying for Storage.csproj.
[ADO Transit] Mono.Posix.NETStandard.dll removed
# Conflicts: # src/Accounts/Accounts/Properties/AssemblyInfo.cs # src/Automation/Automation/Properties/AssemblyInfo.cs # src/Compute/Compute/Properties/AssemblyInfo.cs # src/DataFactory/DataFactoryV2/Properties/AssemblyInfo.cs # src/Network/Network/Properties/AssemblyInfo.cs # src/Resources/Resources/Properties/AssemblyInfo.cs # src/Sql/Sql/Properties/AssemblyInfo.cs
# Conflicts: # src/Network/Network/Properties/AssemblyInfo.cs # src/Storage/Storage.Management/Az.Storage.psd1
# Conflicts: # src/Automation/Automation/Properties/AssemblyInfo.cs # src/Compute/Compute/Properties/AssemblyInfo.cs # src/KeyVault/KeyVault/Properties/AssemblyInfo.cs # src/Network/Network/Properties/AssemblyInfo.cs # src/Resources/Resources/Properties/AssemblyInfo.cs # src/Sql/Sql/Properties/AssemblyInfo.cs # src/Websites/Websites/Properties/AssemblyInfo.cs # tools/StaticAnalysis/StaticAnalysis.csproj # tools/StaticAnalysis/packages.config
…ct instead of the folder of the artifact.
Member
|
failures |
…publish to artifacts and download from artifacts to root.
…h job reference it.
… this is required to work with PublishBuildArtifacts.
Contributor
cormacpayne
approved these changes
Mar 29, 2019
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Massive summary:
\to/in build.proj and Repo.props to support cross-platbuild.projchangesdotnet buildinstead ofdotnet publishpublishmakes sense if you are running the .dlls cross-plat. However, we don't run our .dlls directly (except for StaticAnalysis). PowerShell Core runs our .dlls, so publishing is not necessary.dotnet publishthe StaticAnalysis project to allow it to run cross-plat correctly. Otherwise, it won't work.ContinueOnErrorfrom Exec tasksContinueOnErrordoesn't exist for Exec tasks. The error from the command ran is always returned unless it is suppressed viaIgnoreErrorCodeOnPremCheckstarget/t:Clean,Build,OnPremChecksnow. Other machines (local or ADO), cannot do these checks anyway.GenerateHelptarget-Help.xmlfiles) and runs StaticAnalysis with a new help-only flag (--help-onlyor-h).Fulltarget runClean;Build;OnPremChecks;GenerateHelp;StaticAnalysis;TestDependencyAnalysisandDependencyAnalysisNetcoretargets. Instead, createdStaticAnalysistarget.StaticAnalysistarget runs StaticAnalysis with-s(skip help) always, sinceGenerateHelpdoes help analysisCheckAssemblies.ps1which is additional static analysis outside of the projectTesttarget changesTesttarget was running BinScope and PoliCheck (for some reason). I removed this since it was previously handled in the Build target, but is now handled in theOnPremCheckstarget.Azure.PowerShell.sln. Instead, it uses the one created by Build target. This means that Test cannot run indepedent of Build (which makes sense).UpdateModules.ps1calls in the build process (called once in Build and once in Publish)CodeSign.targetsback into build.proj as they shared properties/logic, and depended on each otherafter.Azure.PowerShell.sln.targetsto build folderartifactsfolder, sinceAzure.PowerShell.slnis built into therebuildfolder. These are accessed by the pipelines.install-pwsh-steps.yml.GenerateHelpandStaticAnalysistarget informationMono.Posix.NETStandard.dllto AccountsMicrosoft.WindowsAzure.Storage.DataMovement.dlland should have been failing static analysis previously. However, we had issues running static analysis properly on Travis. Now that it is running properly on linux and macOS via ADO, this issue was found.'.\Microsoft.WindowsAzure.Storage.dll'from Az.Storage module's RequiredAssemblies listMono.Posix.NETStandard.dllto Storage as it usesMicrosoft.WindowsAzure.Storage.DataMovement.dllRepo.propsin the BatchModelGenerator toolartifacts/StaticAnalysisStaticAnalysisandGenerateHelptargets) go intoartifacts/StaticAnalysisResultsartifacts/TestResultsCheckPoliCheck.ps1not checking only the built modules (it was checking everything inartifacts)GenerateHelp.ps1changesGenerateHelp.ps1to properly access the Exceptions folder intoolsinstead of the one output by the StaticAnalysis buildartifacts. This was fixed.ValidateHelpIssues.csvfrom Exceptions if validation suceededNoHelpIssuesfile toartifacts/StaticAnalysisResultson successSystem.Management.Automationas a framework dll and removedSystem.Configuration.ConfigurationManagerSystem.Configuration.ConfigurationManageris a nupkg that RecoveryServices relies on. So, this cannot be marked as framework since it is in their .psd1.--help-onlyflagartifacts\StaticAnalysis\$(Configuration). StaticAnalysis publishing goes toartifacts\StaticAnalysisartifacts\VersionController