feat: improve web interface #9

Merged
addison merged 14 commits from feat/improve-web-interface into main 2026-02-12 20:47:18 -05:00
Owner
No description provided.
Add BuildARM64Binary() to the Deployer interface, which cross-compiles
the kiosk binary with GOOS=linux GOARCH=arm64 CGO_ENABLED=0 and returns
the path to the built binary.

- RealDeployer: runs 'go build' to a temp file with arm64 env vars
- MockDeployer: returns a stub path for testing
- TUI: calls BuildARM64Binary before mounting root, passes the path
  to InstallBinary
- InstallBinary signature updated to accept binaryPath parameter
  instead of using os.Executable()
- All tests updated with new call sequence

Co-authored-by: Shelley <shelley@exe.dev>
Cover three sections from spec 1 documentation tasks:
- Step-by-step deployment walkthrough from prerequisites to working kiosk
- Configuration options: dietpi.txt, WiFi, systemd service, ports, database
- Troubleshooting: boot issues, WiFi, Chromium, SSH, logs, screen blanking

References README.md for the quick-start overview rather than duplicating it.

Co-authored-by: Shelley <shelley@exe.dev>
Co-authored-by: Shelley <shelley@exe.dev>
Replace runtime cross-compilation (BuildARM64Binary) with a two-stage
build approach:

1. Cross-compile ARM64 binary to deploy/embed/kiosk-arm64
2. Build host binary with -tags=deploy to embed it via go:embed

This removes the Go toolchain dependency from the deploy host.

- Remove BuildARM64Binary() from Deployer interface
- Update InstallBinary to write embedded bytes directly
- Use build tags: 'deploy' embeds real binary, default uses empty placeholder
- Add 'just build-deploy' recipe for the two-stage build
- Update MockDeployer and all tests accordingly

Co-authored-by: Shelley <shelley@exe.dev>
- Remove InstallBinary(rootMount) in favor of DownloadBinary() + InstallBinary(rootMount, binaryPath)
- DownloadBinary() fetches latest ARM64 binary from Forgejo releases API
- InstallBinary() copies the downloaded file to the root partition
- Remove embed_binary.go and embed_binary_dev.go (no longer needed)
- Update MockDeployer to match new interface

Co-authored-by: Shelley <shelley@exe.dev>
- TUI now downloads binary before flashing image
- Update deploy step ordering: download binary → download image → flash → etc.
- Update test expectations for new call sequence

Co-authored-by: Shelley <shelley@exe.dev>
- Remove deploy subcommand and bubbletea import from main.go
- Create cmd/kiosk-deploy/main.go as standalone deploy TUI binary
- main.go is now purely the web server

Co-authored-by: Shelley <shelley@exe.dev>
- Replace build-deploy with cmd/kiosk-deploy build
- Add run-deploy recipe
- Update clean to remove kiosk-deploy
- Update AGENTS.md to reflect split binary and download approach

Co-authored-by: Shelley <shelley@exe.dev>
- Triggers on v* tag push
- Builds kiosk-arm64 with CGO_ENABLED=0 GOOS=linux GOARCH=arm64
- Creates a Forgejo release with the binary attached

Co-authored-by: Shelley <shelley@exe.dev>
Co-authored-by: Shelley <shelley@exe.dev>
Resolve merge conflicts preferring main branch versions:
- release.yml: Forgejo API-based release workflow
- tui.go: progress reporting in deploy flow
- deployer_mock.go: shouldFail check for DownloadBinary
- justfile: top-level CGO_ENABLED export
- specs: download binary from Forgejo releases

Amp-Thread-ID: https://ampcode.com/threads/T-019c54a8-c5d9-709b-b445-ad3e46a7f8b5
Co-authored-by: Amp <amp@ampcode.com>
addison referenced this pull request from a commit 2026-02-12 20:47:19 -05:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
kwila/kiosk!9
No description provided.