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

ci(.github): migrate infra to GHA #33070

Merged
merged 16 commits into from
Nov 1, 2024
Merged

Conversation

Hotell
Copy link
Contributor

@Hotell Hotell commented Oct 17, 2024

Previous Behavior

New Behavior

  • migrates pipelines from ADO to GHA
  • after merge these pipelines will run on every new PR
    • they are not required to pass
    • we will disable them after testing
    • we cannot use workflow_dispatch for proper testing on PR context (branches that can be picked for trigger need to live in upstream repo)
  • VRT pipelines need additional work from VRT team ( follow-up )

pipelines migration status:

  • bundle-size
  • e2e
  • deploy
  • build-test-lint
  • [ ] perf tests Wont do
  • vr-tests (disabled as it will fail)

Additional tasks:

Issues:

  • az cli needs login from GHA

ERROR: Please run 'az login' to setup account.

pipeline link

I guess we need to use ACR ?

- name: ACR login
  run: |
    az acr login --name ${{ secrets.REGISTRY_LOGIN_SERVER }}
  • vr-approval-cli has no flag to setup azure subscription

cc @evancharlton @TristanWatanabe

azure/cli@v2 GHA doesn't support parameters like ADO alternative

Related Issue(s)

  • Fixes #

@fabricteam
Copy link
Collaborator

fabricteam commented Oct 17, 2024

📊 Bundle size report

✅ No changes found

@Hotell Hotell force-pushed the ci/migrate-to-gha branch from 3d7ab27 to 17e2a2a Compare October 17, 2024 10:08
@fabricteam
Copy link
Collaborator

fabricteam commented Oct 17, 2024

🕵 FluentUIV0 No visual regressions between this PR and main

@fabricteam
Copy link
Collaborator

fabricteam commented Oct 17, 2024

Perf Analysis (@fluentui/react-northstar)

⚠️ 1 potential perf regressions detected

Potential regressions comparing to master

Scenario Current PR Ticks Baseline Ticks Ratio Regression Analysis
InputMinimalPerf.default 530 531 1:1 analysis
Perf tests with no regressions
Scenario Current PR Ticks Baseline Ticks Ratio
ListMinimalPerf.default 325 297 1.09:1
ImageMinimalPerf.default 232 214 1.08:1
RefMinimalPerf.default 115 107 1.07:1
HeaderMinimalPerf.default 219 206 1.06:1
SegmentMinimalPerf.default 200 188 1.06:1
DropdownManyItemsPerf.default 394 375 1.05:1
FlexMinimalPerf.default 162 154 1.05:1
HeaderSlotsPerf.default 462 440 1.05:1
BoxMinimalPerf.default 202 195 1.04:1
CheckboxMinimalPerf.default 1158 1115 1.04:1
ListNestedPerf.default 326 313 1.04:1
ListWith60ListItems.default 378 365 1.04:1
LoaderMinimalPerf.default 199 191 1.04:1
ChatDuplicateMessagesPerf.default 152 147 1.03:1
DialogMinimalPerf.default 450 437 1.03:1
DividerMinimalPerf.default 201 196 1.03:1
ProviderMergeThemesPerf.default 661 639 1.03:1
VideoMinimalPerf.default 441 428 1.03:1
AttachmentSlotsPerf.default 655 640 1.02:1
CarouselMinimalPerf.default 271 266 1.02:1
GridMinimalPerf.default 198 194 1.02:1
PortalMinimalPerf.default 85 83 1.02:1
TextMinimalPerf.default 193 190 1.02:1
ButtonMinimalPerf.default 96 95 1.01:1
ChatWithPopoverPerf.default 197 196 1.01:1
DatepickerMinimalPerf.default 3611 3558 1.01:1
DropdownMinimalPerf.default 1433 1413 1.01:1
EmbedMinimalPerf.default 1887 1870 1.01:1
LabelMinimalPerf.default 220 218 1.01:1
MenuMinimalPerf.default 512 506 1.01:1
PopupMinimalPerf.default 353 348 1.01:1
StatusMinimalPerf.default 398 394 1.01:1
CustomToolbarPrototype.default 1475 1455 1.01:1
AvatarMinimalPerf.default 110 110 1:1
ButtonOverridesMissPerf.default 650 651 1:1
ChatMinimalPerf.default 440 438 1:1
ItemLayoutMinimalPerf.default 699 700 1:1
MenuButtonMinimalPerf.default 944 942 1:1
SliderMinimalPerf.default 741 741 1:1
TooltipMinimalPerf.default 1268 1274 1:1
AlertMinimalPerf.default 165 166 0.99:1
AnimationMinimalPerf.default 302 305 0.99:1
ButtonSlotsPerf.default 319 322 0.99:1
ListCommonPerf.default 388 390 0.99:1
TableManyItemsPerf.default 1088 1099 0.99:1
TreeMinimalPerf.default 475 481 0.99:1
TreeWith60ListItems.default 85 86 0.99:1
SplitButtonMinimalPerf.default 2227 2263 0.98:1
IconMinimalPerf.default 392 399 0.98:1
CardMinimalPerf.default 309 318 0.97:1
FormMinimalPerf.default 221 227 0.97:1
ProviderMinimalPerf.default 200 206 0.97:1
RadioGroupMinimalPerf.default 261 269 0.97:1
ToolbarMinimalPerf.default 526 542 0.97:1
LayoutMinimalPerf.default 193 201 0.96:1
RosterPerf.default 1589 1655 0.96:1
TextAreaMinimalPerf.default 285 297 0.96:1
ReactionMinimalPerf.default 210 221 0.95:1
TableMinimalPerf.default 231 242 0.95:1
SkeletonMinimalPerf.default 189 201 0.94:1
AccordionMinimalPerf.default 79 90 0.88:1
AttachmentMinimalPerf.default 76 86 0.88:1

@fabricteam
Copy link
Collaborator

fabricteam commented Oct 17, 2024

Perf Analysis (@fluentui/react-components)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
Avatar mount 644 644 5000
Button mount 316 315 5000
Field mount 1178 1126 5000
FluentProvider mount 707 724 5000
FluentProviderWithTheme mount 81 90 10
FluentProviderWithTheme virtual-rerender 30 33 10
FluentProviderWithTheme virtual-rerender-with-unmount 75 83 10
MakeStyles mount 858 851 50000
Persona mount 1799 1695 5000
SpinButton mount 1392 1419 5000
SwatchPicker mount 1654 1673 5000

@fabricteam
Copy link
Collaborator

fabricteam commented Oct 17, 2024

Perf Analysis (@fluentui/react)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
BaseButton mount 630 634 5000
Breadcrumb mount 1738 1693 1000
Checkbox mount 1730 1718 5000
CheckboxBase mount 1484 1499 5000
ChoiceGroup mount 2996 3042 5000
ComboBox mount 684 682 1000
CommandBar mount 6665 6713 1000
ContextualMenu mount 14125 13853 1000
DefaultButton mount 791 809 5000
DetailsRow mount 2306 2286 5000
DetailsRowFast mount 2244 2272 5000
DetailsRowNoStyles mount 2068 2074 5000
Dialog mount 2825 2725 1000
DocumentCardTitle mount 224 237 1000
Dropdown mount 2028 2036 5000
FocusTrapZone mount 1167 1137 5000
FocusZone mount 1093 1098 5000
GroupedList mount 43408 43333 2
GroupedList virtual-rerender 20681 20764 2
GroupedList virtual-rerender-with-unmount 53161 58613 2
GroupedListV2 mount 245 228 2
GroupedListV2 virtual-rerender 212 228 2
GroupedListV2 virtual-rerender-with-unmount 234 243 2
IconButton mount 1189 1176 5000
Label mount 349 354 5000
Layer mount 2790 2812 5000
Link mount 412 405 5000
MenuButton mount 1012 992 5000
MessageBar mount 21805 21734 5000
Nav mount 2103 2080 1000
OverflowSet mount 810 786 5000
Panel mount 1925 1906 1000
Persona mount 772 764 1000
Pivot mount 893 921 1000
PrimaryButton mount 936 961 5000
Rating mount 4677 4759 5000
SearchBox mount 949 927 5000
Shimmer mount 1961 1927 5000
Slider mount 1332 1363 5000
SpinButton mount 2989 2961 5000
Spinner mount 388 386 5000
SplitButton mount 1929 1859 5000
Stack mount 427 422 5000
StackWithIntrinsicChildren mount 896 891 5000
StackWithTextChildren mount 2752 2827 5000
SwatchColorPicker mount 6524 6473 5000
TagPicker mount 1480 1464 5000
Text mount 411 400 5000
TextField mount 945 931 5000
ThemeProvider mount 878 859 5000
ThemeProvider virtual-rerender 587 587 5000
ThemeProvider virtual-rerender-with-unmount 1305 1308 5000
Toggle mount 632 614 5000
buttonNative mount 195 199 5000

@Hotell Hotell added the CI label Oct 17, 2024
@Hotell Hotell force-pushed the ci/migrate-to-gha branch 5 times, most recently from 290c9aa to 2a15aca Compare October 22, 2024 17:08
@Hotell Hotell changed the title ci(.github): port build-test-lint to GHA ci(.github): migrate infra to GHA Oct 25, 2024
@Hotell Hotell force-pushed the ci/migrate-to-gha branch 2 times, most recently from d1fd83e to afae2a8 Compare October 29, 2024 18:34
@Hotell Hotell force-pushed the ci/migrate-to-gha branch from d23386c to 67910c3 Compare October 30, 2024 08:24
@fabricteam
Copy link
Collaborator

fabricteam commented Oct 30, 2024

🕵 fluentui-web-components-v3 No visual regressions between this PR and main

uses: azure/cli@v2
env:
# ciDefinitionId is set to 205 because that is the ID of the baseline pipeline (https://uifabric.visualstudio.com/fabricpublic/_build?definitionId=205) used by the master branch
CI_DEFINITION_ID: 205
Copy link
Contributor Author

Choose a reason for hiding this comment

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

im not sure how this would be actually used in GHA context

this is what is availabe:

image

Note: I didn't create separate workflow for baseline as we had on ADO (https://github.com/microsoft/fluentui/blob/master/azure-pipelines.vrt-baseline.yml) to mitigate duplication.

@Hotell Hotell force-pushed the ci/migrate-to-gha branch from 0e734f7 to 73c01d3 Compare October 31, 2024 17:36
name: vrscreenshot${{ inputs.fluentVersion }}
path: screenshots

- name: VR App - Create Policy
Copy link
Contributor Author

Choose a reason for hiding this comment

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

this and next step will fail as vrt doesn't work on GHA yet

@@ -0,0 +1,132 @@
name: 'Run and Publish VR Screenshot'
Copy link
Contributor Author

Choose a reason for hiding this comment

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

* @param {import('../../../scripts/triage-bot/src/types.ts').GithubScriptsParams} options
* @returns
*/
async function main(options) {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

we use 3rd party action for now, keeping for future usage

* @param {import('../../../scripts/triage-bot/src/types.ts').GithubScriptsParams & {config:{websiteUrl:string;prId:string}} } options
* @returns
*/
async function main(options) {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

this is all temporary ( whre it lives etc ) - will be tweaked in follow-up prs

@@ -57,3 +55,11 @@ module.exports = {
*/
snapshotFormat: { escapeString: true, printBasicPrototype: true },
};

function isCI() {
Copy link
Contributor Author

Choose a reason for hiding this comment

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

proper isCi check to work on both ADO and GHA

@@ -112,7 +112,7 @@
}
},
"namedInputs": {
"default": ["{projectRoot}/**/*", "sharedGlobals"],
"default": ["{projectRoot}/**/*", "sharedGlobals", "{workspaceRoot}/.github/workflows/pr.yml"],
Copy link
Contributor Author

Choose a reason for hiding this comment

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

temporary cache invalidation that triggers affected on all proejcts if pr.yml has been touched

@@ -0,0 +1,140 @@
name: 'Run and Publish VR Screenshot'
Copy link
Contributor Author

Choose a reason for hiding this comment

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

this pipeline is disabled for now

@@ -0,0 +1,98 @@
name: VRT CI
Copy link
Contributor Author

Choose a reason for hiding this comment

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

this pipeline is disabled for now

@Hotell Hotell marked this pull request as ready for review November 1, 2024 10:48
@Hotell Hotell requested review from a team as code owners November 1, 2024 10:48
@Hotell Hotell merged commit 83b4c2f into microsoft:master Nov 1, 2024
20 checks passed
@Hotell
Copy link
Contributor Author

Hotell commented Nov 1, 2024

pipelines green - got approval - admin merged

@Hotell Hotell deleted the ci/migrate-to-gha branch November 1, 2024 11:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants