Feat: Support running Cortex natively on Windows (no WSL)

オープン
#1,520 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

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

まだ誰も着手していません。

評価

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

調査の方向性

Start with the Windows build failures listed in the issue: core/bootstrap/bootstrap.go, cmd_bob_launch.go, setup_unsupervised.go, cmd_service_platform.go, and setup_probe.go. Then audit the POSIX assumptions named in the issue and check the existing launchd and systemd service implementations. Done means Cortex and agentop build and run natively on Windows, the listed platform needs are addressed, and CI checks Windows builds.

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

説明

Motivation

Some users run coding agents (e.g. opencode) on locked-down Windows VDIs. These don't support virtualization, so WSL isn't an option. Today Cortex only builds and installs on Linux and macOS.

Current state (GOOS=windows GOARCH=amd64 go build on main)
  • cmd/cortex fails in one place: core/bootstrap/bootstrap.go:67 uses syscall.SIGUSR1 (the log-level toggle). With that guarded, the proxy may build as-is.
  • cmd/agentop fails on:
    • cmd_bob_launch.go:220 and setup_unsupervised.go:30: SysProcAttr{Setsid: true}
    • cmd_service_platform.go:342,421 and setup_probe.go:213: syscall.Kill, including Kill(pid, 0) used as a liveness probe
Work needed
  1. Move the Unix-only signal and process code behind _unix.go/_windows.go files:
    • Replace the SIGUSR1 toggle on Windows (e.g. a stats/admin endpoint or an agentop command).
    • Detach processes with CREATE_NEW_PROCESS_GROUP/DETACHED_PROCESS instead of Setsid.
    • Check liveness with OpenProcess instead of Kill(pid, 0).
  2. Add a service backend: agentop service install only knows launchd and systemd. Windows needs a Task Scheduler logon task or a Windows service, or should fall back to --no-service plus the built-in supervisor (cmd/cortex/supervise.go).
  3. Audit the remaining POSIX assumptions:
    • cmd_exec.go relays SIGHUP.
    • Shell-based installer (install.sh) → PowerShell installer or a release zip.
    • $HOME/~/.config paths → %APPDATA%/os.UserConfigDir.
    • File permissions and locking.
    • Trusting the CA cert for the TLS bridge in the Windows cert store.
    • Launching agents (opencode etc.) from agentop.
  4. CI: add a GOOS=windows cross-compile job so it doesn't regress, and ideally a windows-latest test run.

The build results only cover compilation. Nothing has been run on Windows yet, so step 3 is a list of things to check, not confirmed bugs.

Requested by Lucas Showerman (opencode on a client Windows VDI).

主要言語
Go
スター
23
フォーク
44
平均マージ
16時間 37分
マージ済み PR(30日)
250

環境構築

はじめの一歩

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

rossoctl/cortex のほかの issue

rossoctl/cortex の issue をすべて見る

似ている issue

Go の issue をもっと見る

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

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