Skip to content

feat(ui): ssh private key support#5404

Closed
Marvin9 wants to merge 2 commits intomainfrom
Marvin9/feat-ssh-private-key-support
Closed

feat(ui): ssh private key support#5404
Marvin9 wants to merge 2 commits intomainfrom
Marvin9/feat-ssh-private-key-support

Conversation

@Marvin9
Copy link
Copy Markdown
Contributor

@Marvin9 Marvin9 commented Nov 19, 2025

Signed-off-by: Mayursinh Sarvaiya <marvinduff97@gmail.com>
Signed-off-by: Mayursinh Sarvaiya <marvinduff97@gmail.com>
@Marvin9 Marvin9 added this to the v1.9.0 milestone Nov 19, 2025
@Marvin9 Marvin9 self-assigned this Nov 19, 2025
@Marvin9 Marvin9 requested a review from a team as a code owner November 19, 2025 12:01
@Marvin9 Marvin9 added the kind/enhancement An entirely new feature label Nov 19, 2025
@Marvin9 Marvin9 requested a review from a team as a code owner November 19, 2025 12:01
@Marvin9 Marvin9 added area/ui Affects the UI priority/normal This is the priority for most work area/api-server Affects Kargo's API server labels Nov 19, 2025
@netlify
Copy link
Copy Markdown

netlify Bot commented Nov 19, 2025

Deploy Preview for docs-kargo-io ready!

Name Link
🔨 Latest commit 69c481c
🔍 Latest deploy log https://app.netlify.com/projects/docs-kargo-io/deploys/691db17e0cf96200081aa100
😎 Deploy Preview https://deploy-preview-5404.docs.kargo.io
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@codecov
Copy link
Copy Markdown

codecov Bot commented Nov 19, 2025

Codecov Report

❌ Patch coverage is 55.00000% with 9 lines in your changes missing coverage. Please review.
✅ Project coverage is 56.09%. Comparing base (913032d) to head (69c481c).
⚠️ Report is 283 commits behind head on main.

Files with missing lines Patch % Lines
pkg/server/create_credentials_v1alpha1.go 64.70% 4 Missing and 2 partials ⚠️
pkg/server/update_credentials_v1alpha1.go 0.00% 2 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #5404      +/-   ##
==========================================
- Coverage   56.10%   56.09%   -0.01%     
==========================================
  Files         411      411              
  Lines       30063    30077      +14     
==========================================
+ Hits        16868    16873       +5     
- Misses      12221    12227       +6     
- Partials      974      977       +3     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

string username = 6;
// password is the password or token for authentication.
string password = 7;
string ssh_private_key = 9;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We also need to eventually support GitHub App Authentication. Which has the fields:

  • githubAppClientID
  • githubAppPrivateKey
  • githubAppInstallationID

Is continually expanding CreateCredentialsRequest API the sustainable approach to this?

Should UI switch to the Apply endpoint and just create Secret resources with baked-in understanding of the various fields (username/password/privatekey/githubXXXX/etc...)? Then the ConnectRPC API layer never needs to updated.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh. I thought its only sshPrivateKey. You are right, we should start using generic secrets.

Are you suggesting is to remove CreateCredentials approach? even for normal credentials?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jessesuen I had a plan already. It's written down in some issue somewhere. I just need to find it. Credentials come in all different shapes. What I want to do is have Secret templates for all different kinds of creds and you fill in the blanks for whatever type of cred like you're doing a Mad Lib. Adding support for a new kind of credential would be as easy as providing a new template. In the event that a template does not exist for some sort of credential, the option would remain to just give us the cred type and data block.

But, imho, that more comprehensive approach to UI/CLI support for different kinds of credentials ought not to block this ssh-key-specific incremental improvement.

Having said that, I've reached the point of discouraging people from using SSH with Kargo for the simple reason that none of the providers' APIs accept ssh keys as credentials. So when you choose to use ssh creds for basic git operations like cloning, pushing, etc., you force yourself into having to maintain a second set of creds for the same repo(s) so that you can open and merge PRs, etc.

Let's chat about it face to face in the coming week.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@krancour are we going with this or should close PR for now?

@Marvin9 Marvin9 removed this from the v1.9.0 milestone Dec 29, 2025
@krancour
Copy link
Copy Markdown
Member

@Marvin9 I think @jessesuen should make this call. We had a conversation yesterday about deprecating ssh support in v1.10.0 and maybe removing it many releases from now. Probably no sooner than v1.14.0, if ever. So I'm uncertain whether we want to introduce new ssh-related features.

Small tangent, which I've mentioned before: I think how we define creds, in general, is in need of an overhaul, which metadata of some sort describing the different "shapes" of creds so that the UI and CLI alike can better accommodate the many creds that aren't simply username and password. I'm going to put together what I'll call a "creds v2" proposal, but this is a long-term thing.

In the meantime, let's have @jessesuen's make the call on whether to include this feature or not.

@krancour
Copy link
Copy Markdown
Member

Closing in favor of #5978

@Marvin9 Marvin9 closed this Apr 1, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/api-server Affects Kargo's API server area/ui Affects the UI kind/enhancement An entirely new feature priority/normal This is the priority for most work

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants