Self-hosted “Add Device” generates an unusable Station install URL

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

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

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
55/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
docker-compose, elixir
領域
backend, devops

調査の方向性

Start with compose.yaml and trace how the backend receives environment variables, then find where COMMA_STATION_ORIGIN is used to generate the Add Device install command and sign enrollment requests. Check how the externally reachable host and port are preserved through the proxy. Done means the default Compose setup generates a command whose install URL and enrollment signature both work without manual container changes.

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

説明

Summary

In the default self-hosted Compose setup, Settings → Devices → Add Device generates a Station installation command using:

curl -fsSL http://localhost/stations/install.sh | sh -s -- <ticket>

However, no service is exposed on port 80. The web UI is exposed on port 8080, while the Station control-plane endpoint is exposed on port 8081.

As a result, the generated command cannot enroll a Station without manually changing deployment configuration and recreating the backend container.

Environment

  • Comma commit: 66ab3dc9
  • Deployment: repository compose.yaml
  • Host: macOS arm64
  • Container runtime: Podman 6.1.4
  • Default endpoints:
    • Web UI: http://localhost:8080
    • API / Station endpoint: http://localhost:8081

Steps to reproduce

  1. Start the self-hosted deployment using the repository Compose configuration.
  2. Sign in to Comma.
  3. Open Settings → Devices.
  4. Select Add Device.
  5. Copy and run the generated installation command.

Actual behavior

The generated command points to:

http://localhost/stations/install.sh

Port 80 is not listening, so the command initially fails with a connection-refused error.

The observed endpoints are:

http://localhost:8080/stations/install.sh → HTML application shell
http://localhost:8081/stations/install.sh → Station installation script

Changing only the command URL to port 8081 is not sufficient. Enrollment is rejected with:

{"error":"invalid_signature"}

The Station enrollment signature is bound to an origin that does not match the reachable Station endpoint.

Expected behavior

The default self-hosted deployment should generate a Station installation command that works without manual Compose changes.

For example, the self-host configuration could:

  • set COMMA_STATION_ORIGIN to the externally reachable API/Station origin;
  • preserve the external host and port correctly through the reverse proxy; or
  • validate the Station origin during startup and show a clear configuration error.

Workaround

Adding the following deployment setting and recreating the Comma backend container allowed enrollment to succeed:

COMMA_STATION_ORIGIN=http://localhost:8081

The Compose service also needs to pass that variable to the backend process.

Impact

This blocks the first-time Add Device workflow for a default local self-host deployment. The UI presents the command as ready to run, but completing the workflow currently requires understanding the internal port layout, modifying Compose configuration, and recreating the backend container.

主要言語
Elixir
スター
740
フォーク
61
PR マージ指標
30日以内にマージされた PR はありません

環境構築

はじめの一歩

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

AFK-surf/Comma のほかの issue

AFK-surf/Comma の issue をすべて見る

似ている issue

Elixir の issue をもっと見る

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

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