Sign in to Claude and ChatGPT from usine, stored on the gateway

クローズ
#960 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

関連するプルリクエストがすでにマージされています。

  • #965 @usine-phildl による — マージ済み

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
20/100
issue の種類
機能追加
明瞭さ
明確に書かれている
活発さ
停滞
技術スタック
typescript

調査の方向性

Start with apps/docs/src/content/docs/guides/configure-a-gateway.md, packages/gateway/src/admin, and the setup and Configuration → Settings entry points in the web app. Check the pinned Claude Code and Codex login flows, then trace how credentials are handed to the gateway or stored for local harnesses. Done means UI and CLI login work with and without a gateway, the specified failure and credential-leak tests pass, and all gates pass.

索引モデルが issue の本文から書いたものです。

説明

Problem

On an instance with a gateway, the operator sets provider credentials by hand over SSH (apps/docs/src/content/docs/guides/configure-a-gateway.md, step 4): run claude setup-token and paste the token into /etc/usine-gateway/secrets.env, run CODEX_HOME=$(mktemp -d) codex login on a laptop and scp the auth.json to the gateway, set USINE_GATEWAY_CHATGPT_AUTH_FILE, then reload the service. Without a gateway, the operator runs each harness's own login on the orchestrator host. usine itself offers no login step.

Proposed change

  1. Web: a "Connect Claude" and "Connect ChatGPT" step in setup and in Configuration → Settings. Each shows the current state per provider (connected, expires, last refresh, which credential kind: subscription or API key) and offers connect, replace, and disconnect.
  2. CLI: usine login <provider> and usine logout <provider> with the same effect, for headless hosts.
  3. Flow: use each provider CLI's own login, preferring a device-code flow so the browser can be on another machine. Verify what Claude Code (claude setup-token) and Codex (codex login, device auth) support at the pinned versions, and an API-key path for both.
  4. Storage: with a gateway, hand the credential to it over its admin API (packages/gateway/src/admin), which stores it with the same file modes and refresh handling it has today. Without a gateway, store it where the local harnesses read it. Credentials never pass through the operator API's JSON responses, logs, or the browser after the login completes.
  5. Docs: replace the manual steps in the gateway guide and the quickstart's login section with the new step, keeping the manual path as a fallback.

It's a new screen: load the impeccable skill in .agents/skills and follow "How to add UI" in apps/web/README.md. Screenshots under docs/screenshots/<issue>/ for the owner's review before merge.

Acceptance criteria

  • On a fresh instance with a gateway, the operator connects ChatGPT and Claude from the UI or CLI, and a remote attempt runs on those logins with no SSH step.
  • On an instance without a gateway, the same step makes the local worker's harnesses signed in.
  • Tests cover the admin API handoff, a failed or cancelled login, and that no credential appears in API responses or logs.
  • All gates pass.
主要言語
TypeScript
スター
1
フォーク
0
平均マージ
3時間 45分
マージ済み PR(30日)
384

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

basaltbytes/usine のほかの issue

basaltbytes/usine の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。