Department Management

This document describes how to manage workspace departments.

A department in a workspace is a logical unit used for permission control. You can set a workspace role, multiple project roles, and multiple DevOps project roles in a department, and assign users to the department to control user permissions in batches.

Prerequisites

Create a Department

  1. Log in to the KubeSphere web console as ws-admin and go to the demo-ws workspace.

  2. On the left navigation bar, choose Department Management under Workspace Settings, and click Set Department on the right.

  3. In the Set Department dialog box, set the following fields and click OK to create a department.

    Note

    • If a department has already been created in the workspace, you can click Create Department to add more departments to the workspace.

    • You can create multiple departments and multiple sub-departments in each department. To create a subdepartment, select a department on the left department tree and click Create Department on the right.

    • Name: Name of the department.
    • Alias: Alias of the department.
    • Workspace Role: Role of all department members in the current workspace.
    • Project Role: Role of all department members in a project. You can click Add Project to specify multiple project roles. Only one role can be specified for each project.
    • DevOps Project Role: Role of all department members in a DevOps project. You can click Add DevOps Project to specify multiple DevOps project roles. Only one role can be specified for each DevOps project.
  4. Click Close after the department is created. On the Department Management page, the created department is displayed in a department tree on the left.

Assign a User to a Department

  1. On the Department Management page, select a department in the department tree on the left and click Unassigned on the right.

  2. In the unassigned user list, click on the right of a user, and click OK for the displayed message to assign the user to the department.

    Note

    • If permissions provided by the department overlap with existing permissions of the user, new permissions are added to the user. Existing permissions of the user are not affected.
    • Users assigned to a department can perform operations according to the workspace role, project roles, and DevOps project roles associated with the department without being invited to the workspace, projects, and DevOps projects.

Remove a User from a Department

  1. On the Department Management page, select a department in the department tree on the left and click Assigned on the right.
  2. In the assigned user list, click on the right of a user, enter the username in the displayed dialog box, and click OK to remove the user.

Delete and Edit a Department

  1. On the Department Management page, click Set Department.

  2. In the Set Department dialog box, on the left, click the upper level of the department to be edited or deleted.

  3. Click on the right of the department to edit it.

    Note

    For details, see Create a Department.
  4. Click on the right of the department, enter the department name in the displayed dialog box, and click OK to delete the department.

    Note

    • If a department contains sub-departments, the sub-departments will also be deleted.
    • After a department is deleted, the associated roles will be unbound from the users.

Thanks for the feedback. If you have a specific question about how to use KubeSphere, ask it on Slack. Open an issue in the GitHub repo if you want to report a problem or suggest an improvement.