Skip to content

v1.0.0-rc.5

Choose a tag to compare

@github-actions github-actions released this 01 Oct 06:05
· 5 commits to main since this release

Fifth release candidate of Looptrack 1.0.0.

For servers on rc.4, one thing up front: run the one-line install.sh upgrade once by hand. The automatic update does not pick up the new install.sh on its own. "Upgrading from rc.4" below has the line, along with the other steps.

Changes since v1.0.0-rc.4:

  • An out-of-date looptrack or kit takes one command to fix, and that command knows the server URL. Until this release, the setup tool returned looptrack self-update && looptrack issue init … without --url (and a second init when the loop choice was answered), and the "[Update the distributed files]" notice showed the same init. In a terminal without LOOPTRACK_API_URL, that init pointed at the local mode. The setup tool now returns one command that downloads looptrack, verifies its SHA-256 and runs init with --url, --source server and --dist; the notice tells you to call the setup tool instead. Every command in the setup result and the notices uses the absolute path of the looptrack that setup placed. The guide, init, doctor, self-update and the account page no longer point a server user at an init without --url or at a looptrack on the PATH.
  • Upgrading a server with install.sh also updates the looptrack it distributes to users. --upgrade (and the automatic replacement) used to replace only the server's own binary, so sessions running an old looptrack were never told to update. Every install and every --upgrade fills the distribution directory (LOOPTRACK_DIST_DIR) with the binaries for all six platforms, checked against the signed SHA256SUMS. If the distributed looptrack is missing or older than the server, looptrack serve tells administrators in its startup log and in a banner.
  • The setup download replaces a looptrack in ~/.local/bin (on Windows, %LOCALAPPDATA%\Programs\looptrack) that differs from the distributed one, such as the desktop app's symbolic link. Whatever was there used to be kept. The download is skipped only when the SHA-256 matches. A symbolic link is replaced; the file it points to is left alone.
  • Setup commands leave nothing behind in your shell. Pasting one into a terminal used to leave LOOPTRACK_API_URL and LOOPTRACK_PROJECT set, so a later looptrack in another project silently pointed at this one; the download command also left variables and a sum function hiding /usr/bin/sum. In sh the commands run in a subshell or take the variables as a plain prefix. PowerShell wraps them in & { } and restores the previous values. A failed download in sh removes its .part file.
  • If the place of looptrack is missing from your PATH, the setup download adds it: one line in the startup file of your default shell on macOS and Linux, or your user Path on Windows. Reopen the agent app and the terminal afterwards. When looptrack still cannot be found, doctor and the session-start summary say so and show how to fix it.
  • install.sh no longer takes another process's answer on the port for the service's. If an old container held the port, for example, and the service had failed to bind, the installer used to report a finished install anyway. It now stops with an error naming the port. After starting, it checks that the service is active and, with ss, that its main process is the one listening on the port.
  • install.sh checks .env before reading it, and prints no value. An unquoted value with special characters could make the shell print the line (a password included) or run part of it as a command. Such a line now stops install.sh before the file is read, naming only the key.
  • On MySQL, a terminal --upgrade runs the new version's migrate --check before it stops anything. Without LOOPTRACK_SETUP_MIGRATE_DSN it used to stop the service, fail to create the new tables and leave the service stopped. With migrations pending and that variable not set, it lists them and by default stops without changing anything.
  • The secrets guard and the freshness guard's work record read quotes and line continuations the way a shell does, both the POSIX way and the Windows way. A cat of a secret file hidden behind \" is now confirmed; nothing confirmed or recorded before goes through. The git guard is unchanged.
  • CONTRIBUTING.md builds development binaries into ./bin/looptrack. The deployment, updating and AI agents guides and the FAQ cover the changes above.

Upgrading from rc.4:

  • This version adds no database migrations.
  • The one step not to skip: the automatic update keeps running the copy of install.sh saved on the server. Run the one-line upgrade once by hand to get the new one: curl -fsSL https://raw.githubusercontent.com/howashoji/looptrack/main/deploy/install.sh | sudo sh -s -- --upgrade. It fills the distribution directory and adds LOOPTRACK_DIST_DIR to .env even when the server is already on this version. Restart the service if it tells you to.
  • With a compose.yaml written by an older setup, add - ./dist:/dist:ro under services.looptrack.volumes before that --upgrade (create volumes: there if it is missing, as it is with MySQL).
  • If install.sh now stops on a line of .env, put that value in single quotes (KEY='…').
  • Once the server distributes the new looptrack, sessions running an older one get "[Update the distributed files]". Have the agent call the setup tool and run the step it returns; it replaces looptrack and adds its place to the PATH. Then reopen the agent app and the terminal.

Verify downloads with SHA256SUMS and its minisign signature (SHA256SUMS.minisig).
The container image is ghcr.io/howashoji/looptrack:v1.0.0-rc.5.

This is a release candidate. See CHANGELOG.md for the full list of changes.


Looptrack 1.0.0 のリリース候補、5 つ目です。

rc.4 から上げる人へ、先にこれだけは。install.sh の 1 行の更新を、1 度だけ手で実行してください。自動更新が動かすのは、サーバに保存した写しのままです。新しい install.sh は、そのままでは入らない。コマンドは、ほかの手順と一緒に下の「rc.4 から上げるとき」に置きました。

v1.0.0-rc.4 からの変更:

  • 古い looptrack や kit は、サーバの URL を知っている 1 つのコマンドで直せます。以前の setup ツールが返していたのは --url の無い looptrack self-update && looptrack issue init … で、loop の答えがあれば 2 つ目の init まで続いていました。【配布スクリプトの更新】の案内も同じ。LOOPTRACK_API_URL の無い端末だと、この init はローカルモードに向く。この版では、setup ツールが返すコマンドを 1 つにした。中身は、looptrack を取得して SHA-256 を確かめ、--url・--source server・--dist を付けて init する、というもの。案内のほうはコマンドを示す代わりに、setup ツールを呼ぶよう伝えます。setup の結果と案内に出るコマンドは、どれも setup が置いた looptrack の絶対パスで書きます。guide・init・doctor・self-update・アカウント設定の画面も、サーバ版の利用者に --url の無い init や PATH の looptrack を案内しなくなりました。
  • サーバを install.sh で上げれば、利用者に配る looptrack も一緒に新しくなります。これまでの --upgrade(自動の置き換えも)が置き換えていたのは、サーバ自身の実行ファイルだけ。だから古い looptrack を使うセッションには、更新の知らせが出ませんでした。いまは入れるときにも --upgrade のたびにも、6 つの OS・CPU の組の実行ファイルを署名つきの SHA256SUMS で照合してから配布ディレクトリ(LOOPTRACK_DIST_DIR)へ置き、配る looptrack が無いかサーバより古ければ、looptrack serve が起動時のログと管理者の画面の帯で知らせる。
  • ~/.local/bin(Windows は %LOCALAPPDATA%\Programs\looptrack)の looptrack が配布物と違えば、setup の取得が置き換えます。例はデスクトップ版の symlink など。前は何があってもそのまま使っていました。取得を省くのは SHA-256 が一致するときだけ。symlink ならリンクを置き換え、リンクの先には触りません。
  • setup のコマンドは、シェルに何も残さない。以前は端末に貼ると LOOPTRACK_API_URL・LOOPTRACK_PROJECT が残り、別のプロジェクトに移っても looptrack が黙ってこちらを向いていたうえに、取得のコマンドまで変数と、/usr/bin/sum を覆い隠す関数 sum を置いたままにしていました。いまは sh ならサブシェルか export の無い前置で渡し、PowerShell なら & { } で包んで前の値に戻します。sh で取得に失敗すれば .part も消える。
  • looptrack の置き場が PATH に無ければ、setup の取得が足します。macOS・Linux は既定のシェルの起動ファイルに 1 行、Windows は利用者の環境変数 Path。足した後は AI のアプリと端末を開き直してください。それでも looptrack が見つからないなら、doctor とセッション開始時の要約が知らせて、直し方を示す。
  • install.sh が、同じポートにいるほかのプロセスの応答を、サービスの応答と取り違えなくなりました。止め忘れた古いコンテナなどがポートを握っていると、サービスは bind に失敗しているのに、インストールが終わったと報告していた。いまはポートを示して止まる。起動後はサービスが active かどうかに加えて、ss があれば、そのポートで待ち受けているのがサービスのメインのプロセスかまで確かめます。
  • install.sh は .env を読む前に確かめ、値は一切出さない。引用符で囲まない値に特殊な文字があると、シェルがその行(パスワードを含む)を出力したり、値の一部をコマンドとして実行したりしていたので、そういう行があればファイルを読む前に止まり、キーの名前だけを示すようにしました。
  • MySQL なら、端末の --upgrade は何かを止める前に新しい版の migrate --check を実行します。以前は LOOPTRACK_SETUP_MIGRATE_DSN が無いと、サービスを止めてから新しい表を作れずに失敗し、止まったままでした。未適用があってその変数も無いときは、一覧を示し、既定では何も変えずに止まる。
  • 秘密のガードと鮮度ガードの作業の記録は、引用符と行末の継続をシェルと同じように、posix と Windows の両方の読み方で読むので、\" の陰に秘密のファイルの cat を隠したコマンドも確認になります。これまで確認・記録していたものが素通りになることはない。git ガードは変えていません。
  • CONTRIBUTING.md のビルド先は ./bin/looptrack に。配置・更新・AI エージェントのガイドと FAQ にも、上の変更を書き足しました。

rc.4 から上げるとき:

  • この版に DB の移行はありません。
  • 飛ばせないのはこれ。自動更新は、サーバに保存した install.sh の写しを動かし続けます。新しいものにするには、1 行の更新を 1 度だけ手で実行してください: curl -fsSL https://raw.githubusercontent.com/howashoji/looptrack/main/deploy/install.sh | sudo sh -s -- --upgrade。サーバが既にこの版でも、配布ディレクトリをそろえ、.env に LOOPTRACK_DIST_DIR を足す。起動し直すよう出たら、そのとおりに。
  • 古い setup が書いた compose.yaml なら、その --upgrade の前に services.looptrack.volumes へ - ./dist:/dist:ro を足します(MySQL の構成では volumes: が無いので、作ってから足す)。
  • install.sh が .env のある行で止まるようになったら、その値を単引用符で囲んでください(KEY='…')。
  • サーバが新しい looptrack を配り始めると、古いものを使うセッションに【配布スクリプトの更新】が出ます。AI に setup ツールを呼ばせて、返った手順を実行する。それで looptrack が置き換わり、その置き場が PATH に入ります。済んだら AI のアプリと端末を開き直してください。

ダウンロードしたものは SHA256SUMS と minisign の署名(SHA256SUMS.minisig)で確かめられます。
コンテナイメージは ghcr.io/howashoji/looptrack:v1.0.0-rc.5。

リリース候補です。変更の全部は CHANGELOG.md に。


Full Changelog: v1.0.0-rc.4...v1.0.0-rc.5