Restore launcher + fix ghcr image-publish (lowercase)#49
Merged
Conversation
…open it A menu-bar/system-tray app for non-technical users. It draws no UI of its own (the real UI is the SvelteKit app in the browser); it starts Docker if needed, runs `docker compose up` on the prebuilt release stack, waits for health, and opens http://localhost:33000. Tray menu is Open / status / Stop / Restart / Quit (Quit leaves the stack running, like Docker Desktop's tray). Go + fyne.io/systray: one small static-ish binary per OS, no runtime, no packer — so Windows Defender doesn't flag it the way a PyInstaller blob would. The whole thing is ~200 lines. Transparent by construction: it owns no hidden state. It writes ONE file — the release compose — into a per-user folder (~/Library/Application Support/SmartBrain, %APPDATA%\SmartBrain) and shells out to `docker compose` exactly as a person would. Knowledge lives in ./data beside it; back that up and you've backed up everything. No paid signing cert, by design: - macOS: ad-hoc signed (free, all Apple Silicon needs), shipped via Homebrew — no quarantine flag, so no Gatekeeper wall. - Windows: pure-Go exe shipped via winget/Scoop — no Mark-of-the-Web, so no SmartScreen prompt. A browser-downloaded .dmg/.exe is the one channel that would still warn, so it isn't used. Structure keeps the testable logic free of the GUI: stack/ (Docker orchestration) has real unit tests that run on any platform; main.go (systray) is the thin glue. CI builds the macOS universal .app (ad-hoc signed) and the Windows .exe on native runners and attaches them to the release on a tag; it also fails if the embedded compose drifts from compose/docker-compose.release.yml. Verified: stack tests pass, gofmt/vet clean, and the full app (main + systray) cross-compiles for Windows from a throwaway golang container. The macOS/Cocoa build is verified by CI on a macOS runner.
… reject it
The v0.4.0 tag's image publish failed: buildx rejected the cache ref with "repository name
(SecureCloudGroup/SmartBrain_3000) must be lowercase". metadata-action lower-cases the image name for
the tags, but the hand-written cache-from/cache-to refs used ${{ github.repository }} raw. Pin the
lower-cased name once as a job env and use it for both.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two things, both the install/release machinery, recovered/fixed after the merge tangle:
Restore the desktop launcher (was feat(launcher): desktop tray app — one click to start SmartBrain #47 — fell out when its base build(release): prebuilt multi-arch images on ghcr + a pull-based compose #46 was squashed). The Go + systray tray app: starts Docker,
docker compose upthe prebuilt stack, opens the browser. Rebased cleanly onto main (only the launcher commit; the images commit is already on main via build(release): prebuilt multi-arch images on ghcr + a pull-based compose #46).Fix the image publish. The
v0.4.0tag'sRelease imagejob failed: buildx rejected the cache ref with "repository name (SecureCloudGroup/SmartBrain_3000) must be lowercase".metadata-actionlower-cases the image name for the tags, but the hand-writtencache-from/cache-torefs used${{ github.repository }}raw. Now the lower-cased name is pinned once as a job env and used for both.Verification
gofmt/go vet/stacktests clean; full app cross-compiles for Windows; drift check (embedded compose == canonical) passes — and theLauncherworkflow rebuilds the macOS.app+ Windows.exeon real runners for this PRrelease.yml: valid YAML; no raw${{ github.repository }}left in any image/cache refMerge note
Independent of
restore-kb-vaults, based directly onmain— squash-merges safely. Supersedes #47 (please close it).Once both restore PRs are merged, the
release.ymlfix is on main and re-tagging will publish the image correctly.