[PR #11022] feat(desktop): Implement Setting Server Credentials for Desktop using Keyrings #13632

Open
opened 2026-02-16 18:18:28 -05:00 by yindo · 0 comments
Owner

Original Pull Request: https://github.com/anomalyco/opencode/pull/11022

State: open
Merged: No


What does this PR do?

  • Using Rust keyrings stores credentials for servers only for Desktop
  • Also improves the UI to show a different warning status for servers alive but requiring authentication.
  • Adds flow for users setting credentials
  • Ensures first load of opencode sdk always has the credentials loaded in
  • Proper separation of implementation, making sure that the normal WEB UI doesnt have these features or need to have them.

How did you verify your code works?

Ran on my local machine and was able to get this result for Mac.

https://github.com/user-attachments/assets/43b3178c-8ea0-409f-aec9-fe57b85da961

Flow tested

  1. Startup Desktop dev
  2. Create 3 servers, 2 with a password, 1 without
  3. Try to connect these servers to the desktop app
  4. You can close one server and notice it has the RED status
  5. You can open it back but with a new password, if you try to connect you will be prompted to add in new credentials since the last one doesnt work.

Users are asked for permission to access keychains from opencode_server_credentials, they can grant the access always to make sure the app has access to the credential for that server.

**Original Pull Request:** https://github.com/anomalyco/opencode/pull/11022 **State:** open **Merged:** No --- ### What does this PR do? - Using Rust keyrings stores credentials for servers only for Desktop - Also improves the UI to show a different `warning` status for servers alive but requiring authentication. - Adds flow for users setting credentials - Ensures first load of opencode sdk always has the credentials loaded in - Proper separation of implementation, making sure that the normal WEB UI doesnt have these features or need to have them. ### How did you verify your code works? Ran on my local machine and was able to get this result for Mac. https://github.com/user-attachments/assets/43b3178c-8ea0-409f-aec9-fe57b85da961 Flow tested 1) Startup Desktop dev 2) Create 3 servers, 2 with a password, 1 without 3) Try to connect these servers to the desktop app 4) You can close one server and notice it has the RED status 5) You can open it back but with a new password, if you try to connect you will be prompted to add in new credentials since the last one doesnt work. Users are asked for permission to access keychains from `opencode_server_credentials`, they can grant the access always to make sure the app has access to the credential for that server.
yindo added the pull-request label 2026-02-16 18:18:28 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#13632