[go: up one dir, main page]

feat: Add host_keys parameter support to remote mirror API

Problem

Users cannot set SSH host keys via the remote mirror REST API. The host_keys parameter is accepted but silently ignored. Users must use the UI to manually set host keys.

Solution

Add host_keys as an optional parameter to the remote mirror create and update endpoints. This allows users to programmatically set SSH host key fingerprints when creating or updating remote mirrors.

Changes

  • Add host_keys as optional parameter to POST /projects/:id/remote_mirrors
  • Add host_keys as optional parameter to PUT /projects/:id/remote_mirrors/:mirror_id
  • Update RemoteMirrors::CreateService and RemoteMirrors::UpdateService to handle host_keys
  • Update API documentation to reflect writable host_keys parameter

Implementation Notes

  • host_keys should accept an array of objects with fingerprint_sha256 field
  • Validate fingerprint format before persisting
  • Maintain backward compatibility with auto-detected keys
  • Addresses API limitation where host_keys cannot be set programmatically

Merge request reports

Loading