[9.0] [FTR] unify custom role name with Scout (#217882)#218152
Merged
kibanamachine merged 1 commit intoelastic:9.0from Apr 14, 2025
Merged
[9.0] [FTR] unify custom role name with Scout (#217882)#218152kibanamachine merged 1 commit intoelastic:9.0from
kibanamachine merged 1 commit intoelastic:9.0from
Conversation
## Summary
In QAF David added a possibility to spin up MKI project with custom role
set and ready to use.
Originally FTR was using reserved name `'customRole'` for internal
Kibana role to be mapped with native custom role in the project.
Both Scout and FTR use `kbn/test` to simulate SAML authentication, but
the new framework will allow to run the tests in parallel. That said, we
need to support multiple custom role credentials (one pair per worker)
and for simplicity we decided to use the same keys:
To run your tests locally against MKI you need to add a new Cloud user
entry in `user_roles.json`:
```
"custom_role_worker_1": { "username": ..., "password": ... }, // FTR requires only the first entry
"custom_role_worker_2": { "username": ..., "password": ... },
...
```
The test change is minimal:
<img width="559" alt="image"
src="https://github.com/user-attachments/assets/572103a3-13b2-4e6c-b9d2-5e55b03ac51c"
/>
---------
Co-authored-by: Cesare de Cal <cesare.decal@elastic.co>
(cherry picked from commit c4a97e5)
Contributor
💛 Build succeeded, but was flaky
Failed CI StepsTest FailuresMetrics [docs]
cc @dmlemeshko |
dmlemeshko
added a commit
that referenced
this pull request
Apr 15, 2025
# Backport This will backport the following commits from `main` to `8.x`: - [[FTR] unify custom role name with Scout (#217882)](#217882) <!--- Backport version: 9.6.6 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Dzmitry Lemechko","email":"dzmitry.lemechko@elastic.co"},"sourceCommit":{"committedDate":"2025-04-14T17:21:49Z","message":"[FTR] unify custom role name with Scout (#217882)\n\n## Summary\n\nIn QAF David added a possibility to spin up MKI project with custom role\nset and ready to use.\n\nOriginally FTR was using reserved name `'customRole'` for internal\nKibana role to be mapped with native custom role in the project.\n\nBoth Scout and FTR use `kbn/test` to simulate SAML authentication, but\nthe new framework will allow to run the tests in parallel. That said, we\nneed to support multiple custom role credentials (one pair per worker)\nand for simplicity we decided to use the same keys:\n\nTo run your tests locally against MKI you need to add a new Cloud user\nentry in `user_roles.json`:\n\n```\n\"custom_role_worker_1\": { \"username\": ..., \"password\": ... }, // FTR requires only the first entry\n\"custom_role_worker_2\": { \"username\": ..., \"password\": ... },\n...\n```\n\nThe test change is minimal:\n<img width=\"559\" alt=\"image\"\nsrc=\"https://github.com/user-attachments/assets/572103a3-13b2-4e6c-b9d2-5e55b03ac51c\"\n/>\n\n---------\n\nCo-authored-by: Cesare de Cal <cesare.decal@elastic.co>","sha":"c4a97e51e3c9040fb0c955913b06aa0e3b5ba791","branchLabelMapping":{"^v9.1.0$":"main","^v8.19.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","FTR","backport:version","v9.1.0","v8.19.0","v9.0.1"],"title":"[FTR] unify custom role name with Scout","number":217882,"url":"https://github.com/elastic/kibana/pull/217882","mergeCommit":{"message":"[FTR] unify custom role name with Scout (#217882)\n\n## Summary\n\nIn QAF David added a possibility to spin up MKI project with custom role\nset and ready to use.\n\nOriginally FTR was using reserved name `'customRole'` for internal\nKibana role to be mapped with native custom role in the project.\n\nBoth Scout and FTR use `kbn/test` to simulate SAML authentication, but\nthe new framework will allow to run the tests in parallel. That said, we\nneed to support multiple custom role credentials (one pair per worker)\nand for simplicity we decided to use the same keys:\n\nTo run your tests locally against MKI you need to add a new Cloud user\nentry in `user_roles.json`:\n\n```\n\"custom_role_worker_1\": { \"username\": ..., \"password\": ... }, // FTR requires only the first entry\n\"custom_role_worker_2\": { \"username\": ..., \"password\": ... },\n...\n```\n\nThe test change is minimal:\n<img width=\"559\" alt=\"image\"\nsrc=\"https://github.com/user-attachments/assets/572103a3-13b2-4e6c-b9d2-5e55b03ac51c\"\n/>\n\n---------\n\nCo-authored-by: Cesare de Cal <cesare.decal@elastic.co>","sha":"c4a97e51e3c9040fb0c955913b06aa0e3b5ba791"}},"sourceBranch":"main","suggestedTargetBranches":["8.x"],"targetPullRequestStates":[{"branch":"9.0","label":"v9.0.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/218152","number":218152,"state":"MERGED","mergeCommit":{"sha":"086804391acca87ea1baa98e97b1e12886e3e42b","message":"[9.0] [FTR] unify custom role name with Scout (#217882) (#218152)\n\n# Backport\n\nThis will backport the following commits from `main` to `9.0`:\n- [[FTR] unify custom role name with Scout\n(#217882)](https://github.com/elastic/kibana/pull/217882)\n\n\n\n### Questions ?\nPlease refer to the [Backport tool\ndocumentation](https://github.com/sorenlouv/backport)\n\n\n\nCo-authored-by: Dzmitry Lemechko <dzmitry.lemechko@elastic.co>"}},{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/217882","number":217882,"mergeCommit":{"message":"[FTR] unify custom role name with Scout (#217882)\n\n## Summary\n\nIn QAF David added a possibility to spin up MKI project with custom role\nset and ready to use.\n\nOriginally FTR was using reserved name `'customRole'` for internal\nKibana role to be mapped with native custom role in the project.\n\nBoth Scout and FTR use `kbn/test` to simulate SAML authentication, but\nthe new framework will allow to run the tests in parallel. That said, we\nneed to support multiple custom role credentials (one pair per worker)\nand for simplicity we decided to use the same keys:\n\nTo run your tests locally against MKI you need to add a new Cloud user\nentry in `user_roles.json`:\n\n```\n\"custom_role_worker_1\": { \"username\": ..., \"password\": ... }, // FTR requires only the first entry\n\"custom_role_worker_2\": { \"username\": ..., \"password\": ... },\n...\n```\n\nThe test change is minimal:\n<img width=\"559\" alt=\"image\"\nsrc=\"https://github.com/user-attachments/assets/572103a3-13b2-4e6c-b9d2-5e55b03ac51c\"\n/>\n\n---------\n\nCo-authored-by: Cesare de Cal <cesare.decal@elastic.co>","sha":"c4a97e51e3c9040fb0c955913b06aa0e3b5ba791"}},{"branch":"8.x","label":"v8.19.0","branchLabelMappingKey":"^v8.19.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT-->
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
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.
Backport
This will backport the following commits from
mainto9.0:Questions ?
Please refer to the Backport tool documentation