Skip to content

Show Verified badge for commits signed by Gitlab

Igor Drozdov requested to merge id-signed-web-commits into master

What does this MR do and why?

Related issue: Automated/web commits (merge or web IDE commits... (#19185 - closed)

It is now possible to configure Gitaly to use signing_key to sign commits created by Gitaly:

GPG

SSH

This MR detects the commits signed by GitLab signature and displays an appropriate badge.

Steps to verify

  1. Modify Gitaly config (gitaly.config.toml or gitaly-0.praefect.toml file) and specify git.signing_key option:
# # Git settings
[git]
use_bundled_binaries = true
catfile_cache_size = 10
ignore_gitconfig = true
signing_key = "<path-to-gdk>/gitaly/internal/git2go/testdata/signing_ssh_key_ed25519"

signing_ssh_key_ecdsa, signing_ssh_key_ed25519, signing_ssh_key_rsa, signing_gpg_key_rsa from internal/git2go/testdata are used in tests and good enough to be used for testing, but also new keys can be generated.

  1. Open a project and edit a file via Web UI

  2. The created commit should be Verified

Screenshot_2023-06-29_at_16.30.40

Edited by Igor Drozdov

Merge request reports