Skip to content

Add verified badge for SSH signed commits

Brian Williams requested to merge bwill/ssh-commit-verified-badge into master

What does this MR do and why?

Describe in detail what your merge request does and why.

Related to: #343879 (closed)

This MR begins showing the "Verified" badge on SSH signed commits, and also adds the user-facing documentation. The verification logic for the commits was implemented previously with !88693 (merged) and !88693 (merged).

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

  1. Enabled the ssh_commit_signatures feature flag via the Rails console: Feature.enable(:ssh_commit_signatures)

  2. Create an SSH key and add it to your GitLab account.

  3. Configure git to sign commits with SSH by following the documentation included in this MR (please leave feedback if ends up being difficult).

  4. Create a new project.

  5. Clone the repository and change into the project directory

  6. Add a new SSH signed commit and push it

    echo '# SSH Commit Test' > README.md
    git add README.md
    git commit -S -m 'This commit is signed with ssh'
    git push origin main
  7. Reload the project page. There should be a verified badge on your commit.

    Screenshot_2022-11-16_at_4.13.41_PM

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Brian Williams

Merge request reports