Add Deploy Tokens to the Credential Inventory

Release notes

Problem to solve

The credential inventory adds necessary visibility for compliance-minded organizations to know who or what has access to their GitLab systems and resources. It is missing a number of access credentials/tokens to provide a more comprehensive and reliable view of GitLab access and control of that access.

Intended users

User experience goal

An administrator should be able to view information about every Deploy Token in use within their instance.

Proposal

Add a Deploy Tokens tab to the credential inventory and list relevant information.

Tab_group

Name Username Project Creator Created Expires Scopes (Actions)
Test gitlab+deploy-token-1 Group / Project Screenshot_2021-01-13_Credentials___Admin_Area Jan 13, 2021 20201-01-30 read_repository, read_registry, write_registry Revoke
Empty state
Preview
illustrations_no-packages.svg

No deploy tokens have been created yet.

Deploy tokens allow access to packages, your repository, and registry images.

Docs

Out of scope

Creating deploy tokens

Implementation plan

Total combined weight 3️⃣

backend 1️⃣

  1. When the Deploy Tokens tab is active, use the DeployTokens::TokensFinder to find all tokens.

frontend update HAML and add a new empty state 2️⃣

  1. Add a new Deploy tokens tab to the admin credentials inventory view.
  2. When active and there are tokens, display the list of deploy tokens.

Empty state will be added in #351883.

Notes

Deploy tokens are already accessible on group-level. https://docs.gitlab.com/ee/user/project/deploy_tokens/#group-deploy-token

Edited by Jiaan Louw