Go library · ssh deploy · cross-arch builds
goself install a Go binary anywhere, from itself.
A pure Go library that lets a CLI or service install itself on the local host or on remote hosts over ssh. It replicates the running binary, builds the local checkout, rebuilds the exact version for another architecture, or fetches a checksum-verified release.
go get ubunatic.com/goself@latestProject snapshot · measured 2026-10-26
Key facts
12-week commit activity
2026-10-26View 12-week data table
| Week starting | Commits |
|---|---|
| 2026-08-03 | 0 |
| 2026-08-10 | 0 |
| 2026-08-17 | 0 |
| 2026-08-24 | 0 |
| 2026-08-31 | 0 |
| 2026-09-07 | 0 |
| 2026-09-14 | 0 |
| 2026-09-21 | 0 |
| 2026-09-28 | 0 |
| 2026-10-05 | 0 |
| 2026-10-12 | 0 |
| 2026-10-19 | 0 |
Key Features
- Deploys binaries to remote hosts requiring only SSH, /bin/sh, and uname on the target.
- Automatic cross-architecture detection and zero-CGO recompilation from build info.
- Multiple resolution strategies: checkout build, running executable self-stream, release archive, or upstream go install.
- Atomic temp-file staging and rename replacement preventing truncation of running services.
Verified Engineering Milestones
- Bootstrap to v0.2.2: pure Go SSH deploy engine (#001, 84d8e4b)
- Cross-architecture build info inspection and fallback strategies (#005, e259599)
- Consumer onboarding and harness integration (96b6e27)
Stack
Go 1.24, pure-Go SSH client, cross-compilation engine
Why goself
Deploy without remote toolchains
No remote checkout or Go
The target only needs ssh, /bin/sh and uname. goself builds or fetches the binary locally and streams it over the system ssh client.
Cross-architecture by default
When the target's platform differs, goself rebuilds the running binary's exact version from its build info with CGO_ENABLED=0 for that platform.
Safe replacement
Binaries are written to a temp file and renamed over the target, so a running copy is never truncated.
Strategies
Where the binary comes from
| Strategy | Source |
|---|---|
auto |
checkout → build; same platform → self; otherwise → go |
self |
the running executable |
build |
the local checkout, cross-compiled when needed |
release |
a release archive with SHA256 checksum check |
go |
go install pkg@version upstream |
res, err := goself.New(goself.Options{Strategy: goself.Auto}).
Deploy(ctx, goself.Target{Runner: goself.SSH("user@host")})
Project details
Architecture
Layer composition
- Terminal
- CLI self-deployment, SSH streaming
- Desktop
- —
- Inference / AI
- —
- Containers / VM
- OCI container testing
- Web
- —
Engineering story
goself: the story behind the project
Date: 2026-10-25, one session (Claude Opus 5.5 as host, no subagents). - Previous story: none. Baseline is the first commit bc30900 (chore: bootstrap goself). The only earlier study is the topic study prior-art-self-replication.md , written…
Read the engineering story