Fleet: Add created-by to workload resources
Internal ref: SURE-7092
Users are unable to tell who created which GitRepo and when looking at deployed workloads, it's equally unclear whom they belong to.
Idea:
- UI adds user/displayname label to created GitRepos
- Fleet copies those labels onto bundles, etc. (this already works)
- UI can show the created-by name in resource views
Label names to use, https://fleet.rancher.io/ref-configuration#labels :
fleet.cattle.io/created-by-user-id
fleet.cattle.io/created-by-display-name
I don't think we should store the display-name for two reasons, (1) A user may change their name and the data name on resources is then out of sync, (2) From a security point of view, you can look at a GitRepo resource and determine the userid for a given user
Moving to QA blocked as UI team is waiting for the Fleet team to give us feedback about the security concern mentioned above.
There are incoming backend changes for this. Will wait for those changes to come in before testing this feature.
Note that the original work was merged in 2.11 and needs to be verified, should consider doing after https://github.com/rancher/dashboard/issues/15265
@yonasberhe23 can you link to the gh issue that contains the changes blocking QA of this one?
@yonasberhe23 as per https://github.com/rancher/dashboard/issues/15265, we removed fleet.cattle.io/created-by-display-name label from GitRepo YAML and the Created By key:value label from GitRepo's details page.
Moving to QA review.
Tested in https://github.com/rancher/dashboard/issues/15265
@yonasberhe23 as per #15265, we removed
fleet.cattle.io/created-by-display-namelabel from GitRepo YAML and theCreated Bykey:value label from GitRepo's details page. Moving to QA review.
@torchiaf should the Created By label from GitRepo's details page not still be shown, but deducted from the fleet.cattle.io/created-by-user-id? If the deduction is not possible I suppose the user-id is better then having no information who created this resource.
Because at the moment the whole - useful and requested - feature was removed on the UI side, while the user-id i still there and should stay there. So why not show it?