Skip to content

Draft: New Internal Users will not have an Organization

What does this MR do and why?

With the introduction of organizations, users are assigned to an organization. For some users, assigning an organization doesn't make sense, because they are not part of any organization. This MR will prevent assigning an organization for those user types.

This MR removes namespace creation and organization assignment from users created by the Users::Internal module. The following users will not have namespaces or organizations assigned when they are created on a new GitLab installation or a new Cell:

  • Ghost user
  • Alert bot
  • Migration bot
  • Security bot
  • Support bot
  • Automation bot
  • LLM bot
  • Duo Code Review bot
  • Admin bot

Existing accounts for these bots on dotcom, Dedicated, or self-managed installations will not be affected: the change only affects new users created after the MR is merged or on new installations of GitLab. Other types of non-human users such as Service Accounts will not be affected.

References

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After

How to set up and validate locally

  1. Confirm on your local installation that one of the above user types does not yet exist
  2. On the Rails console, create one of above users and ensure it does not have a namespace:
    dcrb = Users::Internal.duo_code_review_bot
    dcrb.persisted?
    dcrb.namespace.present?
  3. Go to a commit and leave a comment mentioning the above user: https://gdk.test:3443/flightjs/Flight/-/commit/8749d49930866a4871fa086adbd7d2057fcc3ebb#7030d0b2f71b999ff89a343de08c414af32fc93a_7_6
  4. Ensure that the mentioned user is still linked appropriately in the comment
Edited by Andrew Evans

Merge request reports

Loading