Host in the menu sets up hosting on this machine or a server
It runs on its own target, apart from the active server's answers, so anyone can open interzone and help the swarm. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
d760c42ca0
commit
134d1167f8
35 files changed
+413
-90
No files matched your search
@@ -157,6 +157,15 @@ or the [Telegram group](https://t.me/+6UwIu9F4gZQxNjM0).
|
||||
firewall), and lets the swarm's members see that the server holds Matrix
|
||||
software. Without sharing, the daemon stops after each run.
|
||||
|
||||
**Hosting without a homeserver.** Anyone can help the swarm: **Host** in
|
||||
the menu sets up this machine or a server over SSH (Linux with systemd,
|
||||
x86 or ARM) to keep the newest publish and share it, everything (about
|
||||
19 GB) or only the container images (about 15 GB). An hourly timer on
|
||||
that machine fetches each new signed publish and lets the old one go;
|
||||
interzone doesn't need to keep running. It listens on TCP 4001 and
|
||||
shows the swarm that it holds Matrix software, like a sharing server.
|
||||
To stop: `systemctl disable --now interzone-ipfs-follow.timer interzone-ipfs`.
|
||||
|
||||
The swarm is private: its key ships with interzone, which keeps the
|
||||
public IPFS network out but isn't a secret. Its entry node is at
|
||||
infamous.g0th.ir (TCP 4001, or WebSocket on yeule.g0th.ir:443). The
|
||||
|
||||
+6
-2
@@ -103,6 +103,7 @@ func New(cfg *config.Config, loaded bool) *App {
|
||||
newMigrateScreen(),
|
||||
newMirrorsScreen(), // its own sidebar section
|
||||
newProbeScreen(), // so is this
|
||||
newHostScreen(), // and this
|
||||
}
|
||||
a.deployBack = a.index("Review")
|
||||
if cfg.Installed() {
|
||||
@@ -136,7 +137,7 @@ func (a *App) jump(n int) tea.Cmd {
|
||||
if n < 0 || n >= len(a.screens) || n == a.step {
|
||||
return nil
|
||||
}
|
||||
if a.screens[n].name() == "Mirrors" {
|
||||
if name := a.screens[n].name(); (name == "Mirrors" || name == "Host") && a.cur().name() != "Mirrors" && a.cur().name() != "Host" {
|
||||
a.mirrorsBack = a.step
|
||||
}
|
||||
if ds, ok := a.screens[n].(*deployScreen); ok {
|
||||
@@ -327,7 +328,7 @@ func (a *App) back() tea.Cmd {
|
||||
switch a.cur().name() {
|
||||
case "Deploy":
|
||||
return a.jump(a.deployBack)
|
||||
case "Mirrors":
|
||||
case "Mirrors", "Host":
|
||||
return a.jump(a.mirrorsBack)
|
||||
case "Manage":
|
||||
return a.jump(0)
|
||||
@@ -430,6 +431,9 @@ func (a *App) stepper(w int) string {
|
||||
if a.cur().name() == "Mirrors" {
|
||||
return " " + sAccent.Render("⇅ Mirrors") + sMuted.Render(" what deploys download") + server
|
||||
}
|
||||
if a.cur().name() == "Host" {
|
||||
return " " + sAccent.Render("⇄ Host") + sMuted.Render(" share interzone's files over IPFS")
|
||||
}
|
||||
if _, ok := a.cur().(toolScreen); ok {
|
||||
return " " + sAccent.Render("◆ Manage") + sMuted.Render(" "+domain) + sFaint.Render(" › ") + sTitle.Render(a.cur().name()) + server
|
||||
}
|
||||
|
||||
@@ -60,6 +60,7 @@ func (a *App) gotoEntries() []gotoEntry {
|
||||
es = append(es, gotoEntry{label: "Mirrors › " + t, id: "side:mirrors:" + strconv.Itoa(i)})
|
||||
}
|
||||
es = append(es, gotoEntry{label: "Test servers", id: "side:test:"})
|
||||
es = append(es, gotoEntry{label: "Host for IPFS", id: "side:host:"})
|
||||
for _, p := range config.Profiles() {
|
||||
if p.Name != config.Active() {
|
||||
es = append(es, gotoEntry{label: "Servers › switch to " + p.Name, id: "side:server:" + p.Name})
|
||||
|
||||
@@ -0,0 +1,183 @@
|
||||
package ui
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"strings"
|
||||
|
||||
"github.com/charmbracelet/bubbles/spinner"
|
||||
tea "github.com/charmbracelet/bubbletea"
|
||||
"github.com/charmbracelet/lipgloss"
|
||||
|
||||
"interzone/internal/config"
|
||||
"interzone/internal/deploy"
|
||||
)
|
||||
|
||||
// ── Host ───────────────────────────────────────────────────────────
|
||||
//
|
||||
// Anyone can help interzone's IPFS swarm without a homeserver: this
|
||||
// machine or a server over SSH keeps the newest publish (everything, or
|
||||
// the images) and shares it (deploy.ActionHost). The run has its own
|
||||
// target, so it doesn't touch the active server's answers.
|
||||
|
||||
type hostEventMsg struct {
|
||||
gen int
|
||||
ev deploy.Event
|
||||
ok bool
|
||||
}
|
||||
|
||||
func (hostEventMsg) owner() string { return "Host" }
|
||||
|
||||
type hostScreen struct {
|
||||
form *form
|
||||
events <-chan deploy.Event
|
||||
cancel context.CancelFunc
|
||||
gen int
|
||||
running bool
|
||||
done bool
|
||||
err error
|
||||
log []string
|
||||
spin spinner.Model
|
||||
scroll int
|
||||
}
|
||||
|
||||
func newHostScreen() *hostScreen {
|
||||
f := newForm(
|
||||
choiceField("parts", "What to host", []string{"all", "images"},
|
||||
[]string{"Everything (about 19 GB)", "Container images only (about 15 GB)"}, "all",
|
||||
"Everything lets other servers set up from scratch through yours: the playbook, OS, Docker and Python packages, and every image. "+
|
||||
"New publishes replace the old one every hour."),
|
||||
choiceField("mode", "Host where?", []string{"local", "ssh"},
|
||||
[]string{"This machine", "A server over SSH"}, "local",
|
||||
"A Linux machine with systemd, x86 or ARM. It needs no homeserver."),
|
||||
textField("host", "Server address", "", "203.0.113.10 or server.example.com", "IP or hostname reachable over SSH."),
|
||||
textField("user", "SSH user", "", "root", ""),
|
||||
textField("port", "SSH port", "", "22", ""),
|
||||
textField("key", "SSH private key", "", "~/.ssh/id_ed25519", "Leave empty to use your SSH agent or default key."),
|
||||
secretField("become", "sudo password", "", "Needed if you're not root and sudo asks for a password."),
|
||||
)
|
||||
f.get("host").required = true
|
||||
remote := func() bool { return f.value("mode") != "ssh" }
|
||||
for _, k := range []string{"host", "user", "port", "key"} {
|
||||
f.get(k).hidden = remote
|
||||
}
|
||||
return &hostScreen{form: f, spin: newSpinner()}
|
||||
}
|
||||
|
||||
func (s *hostScreen) name() string { return "Host" }
|
||||
func (s *hostScreen) title() string { return "Host interzone's files over IPFS" }
|
||||
func (s *hostScreen) typing() bool { return !s.running }
|
||||
func (s *hostScreen) leave(*config.Config) {}
|
||||
func (s *hostScreen) activeForm() *form { return s.form }
|
||||
func (s *hostScreen) keys() [][2]string {
|
||||
if s.running {
|
||||
return [][2]string{{"ctrl+x", "stop"}, {"↑↓", "scroll"}}
|
||||
}
|
||||
return [][2]string{{"enter", "start hosting"}, {"↑↓", "move"}}
|
||||
}
|
||||
|
||||
// enter offers the active server's SSH details, the likeliest machine.
|
||||
func (s *hostScreen) enter(c *config.Config) tea.Cmd {
|
||||
if s.form.value("host") == "" && c.Target.Mode == "ssh" {
|
||||
s.form.get("mode").choice = 1
|
||||
for k, v := range map[string]string{"host": c.Target.Host, "user": c.Target.User, "port": c.Target.Port, "key": c.Target.SSHKey} {
|
||||
s.form.get(k).input.SetValue(v)
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (s *hostScreen) start() tea.Cmd {
|
||||
f := s.form
|
||||
cfg := config.Default()
|
||||
cfg.Target = config.Target{Mode: f.value("mode"), Host: strings.TrimSpace(f.value("host")), User: f.value("user"),
|
||||
Port: f.value("port"), SSHKey: f.value("key"), BecomePass: f.value("become")}
|
||||
if cfg.Target.User == "" {
|
||||
cfg.Target.User = "root"
|
||||
}
|
||||
if cfg.Target.Mode == "ssh" && cfg.Target.Host == "" {
|
||||
s.err = fmt.Errorf("type the server's address first")
|
||||
return nil
|
||||
}
|
||||
ctx, cancel := context.WithCancel(context.Background())
|
||||
s.gen++
|
||||
s.cancel, s.running, s.done, s.err, s.log, s.scroll = cancel, true, false, nil, nil, 0
|
||||
s.events = deploy.Start(ctx, cfg, deploy.Options{Action: deploy.ActionHost, HostParts: f.value("parts")})
|
||||
return tea.Batch(s.spin.Tick, s.wait())
|
||||
}
|
||||
|
||||
func (s *hostScreen) wait() tea.Cmd {
|
||||
ch, gen := s.events, s.gen
|
||||
return func() tea.Msg {
|
||||
ev, ok := <-ch
|
||||
return hostEventMsg{gen, ev, ok}
|
||||
}
|
||||
}
|
||||
|
||||
func (s *hostScreen) update(msg tea.Msg) tea.Cmd {
|
||||
switch m := msg.(type) {
|
||||
case hostEventMsg:
|
||||
if m.gen != s.gen {
|
||||
return nil
|
||||
}
|
||||
if !m.ok {
|
||||
s.running = false
|
||||
return nil
|
||||
}
|
||||
switch {
|
||||
case m.ev.Err != nil:
|
||||
s.err = m.ev.Err
|
||||
case m.ev.Done:
|
||||
s.done = true
|
||||
case m.ev.Line != "":
|
||||
s.log = append(s.log, m.ev.Line)
|
||||
}
|
||||
return s.wait()
|
||||
case spinner.TickMsg:
|
||||
return spinning(s.running, &s.spin, m)
|
||||
case tea.KeyMsg:
|
||||
if s.running {
|
||||
switch m.String() {
|
||||
case "ctrl+x":
|
||||
s.cancel()
|
||||
case "up":
|
||||
s.scroll = max(0, s.scroll-1)
|
||||
case "down":
|
||||
s.scroll++
|
||||
}
|
||||
return nil
|
||||
}
|
||||
if m.String() == "enter" {
|
||||
return s.start()
|
||||
}
|
||||
s.err = nil
|
||||
}
|
||||
if s.running {
|
||||
return nil
|
||||
}
|
||||
return s.form.Update(msg)
|
||||
}
|
||||
|
||||
func (s *hostScreen) view(w, h int) string {
|
||||
intro := sSub.Width(min(w, maxFormWidth)).Render("Help servers set up and update during a blackout: the machine keeps the newest " +
|
||||
"signed copy of what interzone downloads and shares it with interzone's IPFS swarm. It listens on TCP port 4001 " +
|
||||
"(open it in the firewall), and the swarm's members can see that it holds Matrix software.")
|
||||
var status []string
|
||||
switch {
|
||||
case s.running:
|
||||
status = append(status, s.spin.View()+sMuted.Render(" setting up… ctrl+x stops"))
|
||||
case s.err != nil:
|
||||
status = append(status, sBad.Render("✗ "+s.err.Error()))
|
||||
case s.done:
|
||||
status = append(status, sGood.Render("✓ hosting. It keeps going without interzone; enter sets it up again."))
|
||||
}
|
||||
for _, l := range s.log {
|
||||
status = append(status, strings.Split(sMuted.Width(min(w, maxFormWidth)).Render(" "+l), "\n")...)
|
||||
}
|
||||
bottom := strings.Join(status, "\n")
|
||||
formH := max(6, h-lipgloss.Height(intro)-lipgloss.Height(bottom)-3)
|
||||
if s.running || s.done {
|
||||
formH = min(formH, 6)
|
||||
}
|
||||
return intro + "\n\n" + s.form.View(w, formH) + "\n\n" + bottom
|
||||
}
|
||||
@@ -227,6 +227,8 @@ func (a *App) compactWhere() string {
|
||||
return sAccent.Render("⇅ Mirrors")
|
||||
case sideTest:
|
||||
return sAccent.Render("⌖ Test")
|
||||
case sideHost:
|
||||
return sAccent.Render("⇄ Host")
|
||||
case sideServers:
|
||||
return sAccent.Render("▤ Servers")
|
||||
}
|
||||
|
||||
@@ -99,6 +99,12 @@ func TestLayout(t *testing.T) {
|
||||
{"tokens", openTokens},
|
||||
{"rooms", openRooms},
|
||||
{"test", openTest},
|
||||
{"host", func(a *App) {
|
||||
a.jump(a.index("Host"))
|
||||
hs := a.cur().(*hostScreen)
|
||||
hs.done, hs.log = true, []string{"installing IPFS v0.43.1 (from https://infamous.g0th.ir/.ipfs)",
|
||||
"the server is downloading about 19 GB in the background and shares it as it arrives"}
|
||||
}},
|
||||
{"maintenance", func(a *App) { deliver(a, maintainMsg("vacuum")) }},
|
||||
{"users-bridge", func(a *App) {
|
||||
openUsers(a)
|
||||
|
||||
@@ -297,6 +297,8 @@ func (a *App) sideClick(id string) tea.Cmd {
|
||||
return a.switchServer(switchServerMsg{name: arg, cfg: c})
|
||||
case "test":
|
||||
return a.jump(a.index("Test"))
|
||||
case "host":
|
||||
return a.jump(a.index("Host"))
|
||||
case "mirrors":
|
||||
n, _ := strconv.Atoi(arg)
|
||||
a.screens[a.index("Mirrors")].(*mirrorsScreen).show(n)
|
||||
@@ -323,6 +325,8 @@ func (a *App) sideClick(id string) tea.Cmd {
|
||||
return a.jump(a.index("Mirrors"))
|
||||
case "test":
|
||||
return a.jump(a.index("Test"))
|
||||
case "host":
|
||||
return a.jump(a.index("Host"))
|
||||
case "servers":
|
||||
return a.jump(a.index("Servers"))
|
||||
}
|
||||
|
||||
+21
-3
@@ -36,10 +36,11 @@ const (
|
||||
sideManage
|
||||
sideMirrors
|
||||
sideTest
|
||||
sideHost
|
||||
sideServers
|
||||
)
|
||||
|
||||
var sectionNames = map[sideSection]string{sideSetup: "setup", sideManage: "manage", sideMirrors: "mirrors", sideTest: "test", sideServers: "servers"}
|
||||
var sectionNames = map[sideSection]string{sideSetup: "setup", sideManage: "manage", sideMirrors: "mirrors", sideTest: "test", sideHost: "host", sideServers: "servers"}
|
||||
|
||||
func sideOpenFile() string { return filepath.Join(config.Dir(), "sidebar-open") }
|
||||
|
||||
@@ -63,7 +64,7 @@ func loadSideOpen() map[sideSection]bool {
|
||||
|
||||
func (a *App) saveSideOpen() {
|
||||
var names []string
|
||||
for _, sec := range []sideSection{sideSetup, sideManage, sideMirrors, sideTest, sideServers} {
|
||||
for _, sec := range []sideSection{sideSetup, sideManage, sideMirrors, sideTest, sideHost, sideServers} {
|
||||
if a.sideOpen[sec] {
|
||||
names = append(names, sectionNames[sec])
|
||||
}
|
||||
@@ -144,6 +145,8 @@ func (a *App) section() sideSection {
|
||||
return sideMirrors
|
||||
case name == "Test":
|
||||
return sideTest
|
||||
case name == "Host":
|
||||
return sideHost
|
||||
case name == "Manage", a.isTool(a.step):
|
||||
return sideManage
|
||||
case name == "Deploy":
|
||||
@@ -176,6 +179,7 @@ func (a *App) sidebar(h int) string {
|
||||
}
|
||||
lines := []string{mark("side:head:setup", icon(sideSetup, "◇")), "", mark("side:head:manage", icon(sideManage, "◆")), "",
|
||||
mark("side:head:mirrors", icon(sideMirrors, "⇅")), "", mark("side:head:test", icon(sideTest, "⌖")), "",
|
||||
mark("side:head:host", icon(sideHost, "⇄")), "",
|
||||
mark("side:head:servers", icon(sideServers, "▤"))}
|
||||
if !a.sideCollapsed {
|
||||
lines = append(lines, "", "", sFaint.Render(" ⋯")) // too narrow; ctrl+b does nothing here
|
||||
@@ -317,7 +321,21 @@ func (a *App) menu() []menuSection {
|
||||
servers.items = append(servers.items, it)
|
||||
}
|
||||
}
|
||||
return []menuSection{setup, manage, mirrors, test, servers}
|
||||
host := menuSection{sec: sideHost, icon: "⇄", title: "Host"}
|
||||
if a.sideOpen[sideHost] {
|
||||
hs := a.screens[a.index("Host")].(*hostScreen)
|
||||
it := menuItem{id: "side:host:", icon: sFaint.Render("·"), label: "Host for IPFS", on: sec == sideHost}
|
||||
switch {
|
||||
case hs.running:
|
||||
it.icon = hs.spin.View()
|
||||
case hs.err != nil:
|
||||
it.icon = sBad.Render("✗")
|
||||
case hs.done:
|
||||
it.icon = sGood.Render("✓")
|
||||
}
|
||||
host.items = append(host.items, it)
|
||||
}
|
||||
return []menuSection{setup, manage, mirrors, test, host, servers}
|
||||
}
|
||||
|
||||
// menuHead is a section's heading: an arrow showing whether it's open.
|
||||
|
||||
+4
-4
@@ -14,10 +14,10 @@
|
||||
│ ││ │
|
||||
│ ▸ Test ││ ○ Exim email relay needs settings │
|
||||
│ ││ Lets services send email (password resets, notifications). │
|
||||
│ ▾ Servers ││ │
|
||||
│ ● example.org ││ ○ Serve the base domain │
|
||||
│ ││ Host a simple page and .well-known files on <domain> itself (only if nothing els… │
|
||||
│ ││ │
|
||||
│ ▸ Host ││ │
|
||||
│ ││ ○ Serve the base domain │
|
||||
│ ▾ Servers ││ Host a simple page and .well-known files on <domain> itself (only if nothing els… │
|
||||
│ ● example.org ││ │
|
||||
│ ││ ○ Dynamic DNS (ddclient) needs settings │
|
||||
│ ││ Keep DNS records updated when your server has a changing IP. │
|
||||
│ ││ │
|
||||
|
||||
+4
-4
@@ -21,10 +21,10 @@
|
||||
│ ││ │ Load 1.20 0.90 0.70 1, 5, 15 min │ │
|
||||
│ ▸ Test ││ │ Memory ███████████████░░░░░░░░░ 5.0 GB / 8.0 GB │ │
|
||||
│ ││ │ Swap ████████████░░░░░░░░░░░░ 1.0 GB / 2.0 GB │ │
|
||||
│ ▾ Servers ││ │ Disk / ███████████████████░░░░░ 18.0 GB free / 80.0 GB │ │
|
||||
│ ● example.org ││ │ Next backup Tue 0000-00-00 00:00:00 UTC │ │
|
||||
│ ││ ╰────────────────────────────────────────────────────────────────────────────────────╯ │
|
||||
│ ││ ╭────────────────────────────────────────────────────────────────────────────────────╮ │
|
||||
│ ▸ Host ││ │ Disk / ███████████████████░░░░░ 18.0 GB free / 80.0 GB │ │
|
||||
│ ││ │ Next backup Tue 0000-00-00 00:00:00 UTC │ │
|
||||
│ ▾ Servers ││ ╰────────────────────────────────────────────────────────────────────────────────────╯ │
|
||||
│ ● example.org ││ ╭────────────────────────────────────────────────────────────────────────────────────╮ │
|
||||
│ ││ │ Heaviest containers use 5% of 4 cores │ │
|
||||
│ ││ │ mem cpu │ │
|
||||
│ ││ │ synapse ██████████████ 7.6% 4.10% │ │
|
||||
|
||||
+4
-4
@@ -21,10 +21,10 @@
|
||||
│ ││ ╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │
|
||||
│ ▸ Test ││ │ Last 14 days │ │
|
||||
│ ││ │ Load ▄▄▅▄▃▂▂▃▄▅▄▄▃▂▂▃▄▅▄▄▃▂▂▃▄▅▄▃▂▂▃▄▄▅▄▃▂▂▃▄▄▅▄▃▂▂▃▄▅▄▄▃▂▂▃▄▅▄▄▃▂▃▄▄▅▄▃▂▂▃▄▄▅▄▃▂▂▃▄▅▄▄▃▂▂▃▄▅▄▄▃▂▂▃▄▅▄▃▂▂▃▄▄▅▄▃▂▂▃ 27% peak 50% │ │
|
||||
│ ▾ Servers ││ │ Memory ▅▆▆▅▅▄▄▅▅▆▆▅▅▄▄▅▅▆▆▅▅▄▅▅▅▆▅▅▅▄▅▅▆▆▅▅▄▄▅▅▆▆▅▅▄▄▅▅▆▆▅▅▄▄▅▅▆▅▅▅▄▅▅▅▆▅▅▄▄▅▅▆▆▅▅▄▄▅▅▆▆▅▅▄▄▅▅▆▆▅▅▄▄▅▅▆▅▅▄▄▅▅▆▆▅▅▄▄▅ 54% peak 65% │ │
|
||||
│ ● example.org ││ │ Disk ▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆ 78% full in ~52 days │ │
|
||||
│ ││ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ │
|
||||
│ ││ ╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │
|
||||
│ ▸ Host ││ │ Memory ▅▆▆▅▅▄▄▅▅▆▆▅▅▄▄▅▅▆▆▅▅▄▅▅▅▆▅▅▅▄▅▅▆▆▅▅▄▄▅▅▆▆▅▅▄▄▅▅▆▆▅▅▄▄▅▅▆▅▅▅▄▅▅▅▆▅▅▄▄▅▅▆▆▅▅▄▄▅▅▆▆▅▅▄▄▅▅▆▆▅▅▄▄▅▅▆▅▅▄▄▅▅▆▆▅▅▄▄▅ 54% peak 65% │ │
|
||||
│ ││ │ Disk ▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆▆ 78% full in ~52 days │ │
|
||||
│ ▾ Servers ││ ╰────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯ │
|
||||
│ ● example.org ││ ╭────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮ │
|
||||
│ ││ │ Certificates │ │
|
||||
│ ││ │ ✓ Synapse matrix.example.org 60 days until 0000-00-00 · R11 │ │
|
||||
│ ││ │ ! Element Web element.example.org 12 days until 0000-00-00 · R11 │ │
|
||||
|
||||
+4
-4
@@ -14,10 +14,10 @@
|
||||
│ ││ │
|
||||
│ ▸ Test ││ ╭──────────────────────────────────────────────────────────────────────────────────╮ │
|
||||
│ ││ │ ◉ Synapse the reference server · recommended │ │
|
||||
│ ▾ Servers ││ │ │ │
|
||||
│ ● example.org ││ │ Most complete and best supported implementation. Every component in this │ │
|
||||
│ ││ │ tool works with it. │ │
|
||||
│ ││ ╰──────────────────────────────────────────────────────────────────────────────────╯ │
|
||||
│ ▸ Host ││ │ │ │
|
||||
│ ││ │ Most complete and best supported implementation. Every component in this │ │
|
||||
│ ▾ Servers ││ │ tool works with it. │ │
|
||||
│ ● example.org ││ ╰──────────────────────────────────────────────────────────────────────────────────╯ │
|
||||
│ ││ ○ Continuwuity lightweight Rust server │
|
||||
│ ││ ○ Tuwunel lightweight Rust server │
|
||||
│ ││ ○ Conduit minimal Rust server │
|
||||
|
||||
+36
@@ -0,0 +1,36 @@
|
||||
◢◤ interzone matrix, deployed anywhere ONLINE
|
||||
╭────────────────────────╮╭────────────────────────────────────────────────────────────────────────────────────────────╮
|
||||
│ ▸ Setup ││ │
|
||||
│ ││ Host interzone's files over IPFS │
|
||||
│ ▸ Manage example.org ││ │
|
||||
│ ││ Help servers set up and update during a blackout: the machine keeps the newest signed │
|
||||
│ ▸ Mirrors ││ copy of what interzone downloads and shares it with interzone's IPFS swarm. It listens │
|
||||
│ ││ on TCP port 4001 (open it in the firewall), and the swarm's members can see that it │
|
||||
│ ▸ Test ││ holds Matrix software. │
|
||||
│ ││ │
|
||||
│ ▾ Host ││ ▌ What to host │
|
||||
│ ▌ ✓ Host for IPFS ││ ▌ ◉ Everything (about 19 GB) ○ Container images only (about 15 GB) │
|
||||
│ ││ ▌ Everything lets other servers set up from scratch through yours: the playbook, │
|
||||
│ ▾ Servers ││ ▌ OS, Docker and Python packages, and every image. New publishes replace the old │
|
||||
│ ● example.org ││ ▌ one every hour. │
|
||||
│ ││ ▼ more below │
|
||||
│ ││ │
|
||||
│ ││ ✓ hosting. It keeps going without interzone; enter sets it up again. │
|
||||
│ ││ installing IPFS v0.43.1 (from https://infamous.g0th.ir/.ipfs) │
|
||||
│ ││ the server is downloading about 19 GB in the background and shares it as it arrives │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ◫ auto (wide) ctrl+l ││ │
|
||||
│ ◐ interzone ctrl+y ││ │
|
||||
│ ◂ fold ctrl+b menu ││ │
|
||||
╰────────────────────────╯╰────────────────────────────────────────────────────────────────────────────────────────────╯
|
||||
enter start hosting · ↑↓ move · esc back · ctrl+c quit
|
||||
+40
@@ -0,0 +1,40 @@
|
||||
◢◤ ⇄ Host
|
||||
Host interzone's files over IPFS
|
||||
|
||||
Help servers set up and update during a
|
||||
blackout: the machine keeps the newest
|
||||
signed copy of what interzone downloads and
|
||||
shares it with interzone's IPFS swarm. It
|
||||
listens on TCP port 4001 (open it in the
|
||||
firewall), and the swarm's members can see
|
||||
that it holds Matrix software.
|
||||
|
||||
▌ What to host
|
||||
▌ ◉ Everything (about 19 GB)
|
||||
▌ ○ Container images only (about 15 GB)
|
||||
▌ Everything lets other servers set up
|
||||
▌ from scratch through yours: the
|
||||
▼ more below
|
||||
|
||||
✓ hosting. It keeps going without interzone;
|
||||
installing IPFS v0.43.1 (from
|
||||
https://infamous.g0th.ir/.ipfs)
|
||||
the server is downloading about 19 GB in
|
||||
the background and shares it as it arrives
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
‹ back ≡ menu start hosti… ⋯
|
||||
+20
@@ -0,0 +1,20 @@
|
||||
◢◤ ⇄ Host
|
||||
Host interzone's files over IPFS
|
||||
Help servers set up and update during a
|
||||
blackout: the machine keeps the newest signed
|
||||
copy of what interzone downloads and shares it
|
||||
with interzone's IPFS swarm. It listens on TCP
|
||||
port 4001 (open it in the firewall), and the
|
||||
swarm's members can see that it holds Matrix
|
||||
software.
|
||||
|
||||
▌ What to host
|
||||
▌ ◉ Everything (about 19 GB)
|
||||
▌ ○ Container images only (about 15 GB)
|
||||
▌ Everything lets other servers set up from
|
||||
▌ scratch through yours: the playbook, OS,
|
||||
▼ more below
|
||||
|
||||
✓ hosting. It keeps going without interzone; e
|
||||
installing IPFS v0.43.1 (from
|
||||
‹ back ≡ menu start hosting… ⋯
|
||||
+2
-2
@@ -21,14 +21,14 @@
|
||||
│ ││ │
|
||||
│ ▸ Test ││ │
|
||||
│ ││ │
|
||||
│ ▸ Host ││ │
|
||||
│ ││ │
|
||||
│ ▾ Servers ││ │
|
||||
│ ● example.org ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ◫ auto (wide) ctrl+l ││ │
|
||||
│ ◐ interzone ctrl+y ││ │
|
||||
│ ◂ fold ctrl+b menu ││ │
|
||||
|
||||
+4
-4
@@ -21,10 +21,10 @@
|
||||
│ ││ + Add a user a │
|
||||
│ ▸ Test ││ @ Manage users m │
|
||||
│ ││ # Manage rooms R │
|
||||
│ ▾ Servers ││ │
|
||||
│ ● example.org ││ Data ───────────────────────────────────────────────────────────────────────────────── │
|
||||
│ ││ ⇩ Back up the database b │
|
||||
│ ││ ◷ Backups s │
|
||||
│ ▸ Host ││ │
|
||||
│ ││ Data ───────────────────────────────────────────────────────────────────────────────── │
|
||||
│ ▾ Servers ││ ⇩ Back up the database b │
|
||||
│ ● example.org ││ ◷ Backups s │
|
||||
│ ││ ↺ Restore a backup e │
|
||||
│ ││ ↶ Roll back z │
|
||||
│ ││ ◔ Disk space D │
|
||||
|
||||
+4
-4
@@ -21,10 +21,10 @@
|
||||
│ ││ @ Manage users m │
|
||||
│ ▸ Test ││ # Manage rooms R │
|
||||
│ ││ │
|
||||
│ ▾ Servers ││ Data ───────────────────────────────────────────────────────────────────────────────── │
|
||||
│ ● example.org ││ ⇩ Back up the database b │
|
||||
│ ││ ◷ Backups s │
|
||||
│ ││ ↺ Restore a backup e │
|
||||
│ ▸ Host ││ Data ───────────────────────────────────────────────────────────────────────────────── │
|
||||
│ ││ ⇩ Back up the database b │
|
||||
│ ▾ Servers ││ ◷ Backups s │
|
||||
│ ● example.org ││ ↺ Restore a backup e │
|
||||
│ ││ ↶ Roll back z │
|
||||
│ ││ ◔ Disk space D │
|
||||
│ ││ ⌫ Vacuum the database V │
|
||||
|
||||
+4
-4
@@ -21,10 +21,10 @@
|
||||
│ ││ + Add a user a │
|
||||
│ ▸ Test ││ @ Manage users m │
|
||||
│ ││ # Manage rooms R │
|
||||
│ ▾ Servers ││ │
|
||||
│ ● example.org ││ Data ───────────────────────────────────────────────────────────────────────────────── │
|
||||
│ ││ ⇩ Back up the database b │
|
||||
│ ││ ◷ Backups s │
|
||||
│ ▸ Host ││ │
|
||||
│ ││ Data ───────────────────────────────────────────────────────────────────────────────── │
|
||||
│ ▾ Servers ││ ⇩ Back up the database b │
|
||||
│ ● example.org ││ ◷ Backups s │
|
||||
│ ││ ↺ Restore a backup e │
|
||||
│ ││ ↶ Roll back z │
|
||||
│ ││ ◔ Disk space D │
|
||||
|
||||
+1
-1
@@ -25,6 +25,7 @@
|
||||
|
||||
⇅ Mirrors ▸
|
||||
⌖ Test ▸
|
||||
⇄ Host ▸
|
||||
▤ Servers ▾
|
||||
╭───────────────────╮
|
||||
│ ● example.org │
|
||||
@@ -36,5 +37,4 @@
|
||||
|
||||
|
||||
|
||||
|
||||
✕ close
|
||||
+4
-4
@@ -11,10 +11,10 @@
|
||||
│ ││ checked just now · r checks again │
|
||||
│ ▸ Test ││ The playbook, and the roles it pins at their versions from │
|
||||
│ ││ https://itsjustadream.g0th.ir/ │
|
||||
│ ▾ Servers ││ │
|
||||
│ ● example.org ││ ✗ cinny has no v4.12.8-0 yet; the … https://itsjustadre…ible-role-cinny.git │
|
||||
│ ││ ✓ playbook HEAD 1a2b3c4d5e https://itsjustadre…cker-ansible-deploy │
|
||||
│ ││ ✓ auxiliary v2.0.0-0 https://itsjustadre…nsible-role-aux.git │
|
||||
│ ▸ Host ││ │
|
||||
│ ││ ✗ cinny has no v4.12.8-0 yet; the … https://itsjustadre…ible-role-cinny.git │
|
||||
│ ▾ Servers ││ ✓ playbook HEAD 1a2b3c4d5e https://itsjustadre…cker-ansible-deploy │
|
||||
│ ● example.org ││ ✓ auxiliary v2.0.0-0 https://itsjustadre…nsible-role-aux.git │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
|
||||
+4
-4
@@ -11,10 +11,10 @@
|
||||
│ ││ checked just now · r checks again │
|
||||
│ ▸ Test ││ The playbook, and the roles it pins at their versions from https://itsjustadream.g0th.ir/ │
|
||||
│ ││ │
|
||||
│ ▾ Servers ││ ✗ cinny has no v4.12.8-0 yet; the mirror may be behind https://itsjustadream.g0th.ir/moth…self-hosting/ansible-role-cinny.git │
|
||||
│ ● example.org ││ ✓ playbook HEAD 1a2b3c4d5e https://itsjustadream.g0th.ir/spantaleev/matrix-docker-ansible-deploy │
|
||||
│ ││ ✓ auxiliary v2.0.0-0 https://itsjustadream.g0th.ir/moth…l-self-hosting/ansible-role-aux.git │
|
||||
│ ││ │
|
||||
│ ▸ Host ││ ✗ cinny has no v4.12.8-0 yet; the mirror may be behind https://itsjustadream.g0th.ir/moth…self-hosting/ansible-role-cinny.git │
|
||||
│ ││ ✓ playbook HEAD 1a2b3c4d5e https://itsjustadream.g0th.ir/spantaleev/matrix-docker-ansible-deploy │
|
||||
│ ▾ Servers ││ ✓ auxiliary v2.0.0-0 https://itsjustadream.g0th.ir/moth…l-self-hosting/ansible-role-aux.git │
|
||||
│ ● example.org ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
|
||||
+4
-4
@@ -14,10 +14,10 @@
|
||||
│ ││ │ • Sable │ │
|
||||
│ ▸ Test ││ │ Login • Matrix Authentication Service │ │
|
||||
│ ││ │ • Ketesa admin panel │ │
|
||||
│ ▾ Servers ││ │ Calls • Element Call │ │
|
||||
│ ● example.org ││ ╰────────────────────────────────────────────────────────────────────────────────╯ │
|
||||
│ ││ Bridge hub Synapse · 11 components │
|
||||
│ ││ Public community Synapse · 8 components │
|
||||
│ ▸ Host ││ │ Calls • Element Call │ │
|
||||
│ ││ ╰────────────────────────────────────────────────────────────────────────────────╯ │
|
||||
│ ▾ Servers ││ Bridge hub Synapse · 11 components │
|
||||
│ ● example.org ││ Public community Synapse · 8 components │
|
||||
│ ││ Lightweight Tuwunel · 3 components │
|
||||
│ ││ │
|
||||
│ ││ Or only the homeserver, and pick the components yourself │
|
||||
|
||||
+4
-4
@@ -14,10 +14,10 @@
|
||||
│ ││ ╰──────────────────────────────────────────────────────────────────────╯ │
|
||||
│ ▸ Test ││ │
|
||||
│ ││ ╭──────────────────────────────────────────────────────────────────────╮ │
|
||||
│ ▾ Servers ││ │ ✓ Ready to deploy. │ │
|
||||
│ ● example.org ││ ╰──────────────────────────────────────────────────────────────────────╯ │
|
||||
│ ││ │
|
||||
│ ││ Pre-deploy checks ⠋ checking the server… 0s c stop │
|
||||
│ ▸ Host ││ │ ✓ Ready to deploy. │ │
|
||||
│ ││ ╰──────────────────────────────────────────────────────────────────────╯ │
|
||||
│ ▾ Servers ││ │
|
||||
│ ● example.org ││ Pre-deploy checks ⠋ checking the server… 0s c stop │
|
||||
│ ││ │
|
||||
│ ││ ○ Synapse matrix.example.org │
|
||||
│ ││ ○ Element Web element.example.org │
|
||||
|
||||
+2
-2
@@ -21,14 +21,14 @@
|
||||
│ ││ │
|
||||
│ ▸ Test ││ │
|
||||
│ ││ │
|
||||
│ ▸ Host ││ │
|
||||
│ ││ │
|
||||
│ ▾ Servers ││ │
|
||||
│ ● example.org ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ◫ auto (wide) ctrl+l ││ │
|
||||
│ ◐ interzone ctrl+y ││ │
|
||||
│ ◂ fold ctrl+b menu ││ │
|
||||
|
||||
+4
-4
@@ -14,10 +14,10 @@
|
||||
│ ││ › │
|
||||
│ ▸ Test ││ │
|
||||
│ ││ │
|
||||
│ ▾ Servers ││ ◆ Downloads ────────────────────────────────────────────────────────────────────────── │
|
||||
│ ● example.org ││ │
|
||||
│ ││ Network situation │
|
||||
│ ││ ◉ Normal internet ○ Blackout: in-country mirrors only │
|
||||
│ ▸ Host ││ ◆ Downloads ────────────────────────────────────────────────────────────────────────── │
|
||||
│ ││ │
|
||||
│ ▾ Servers ││ Network situation │
|
||||
│ ● example.org ││ ◉ Normal internet ○ Blackout: in-country mirrors only │
|
||||
│ ││ ○ IPFS: from interzone's swarm │
|
||||
│ ││ │
|
||||
│ ││ Playbook git repository │
|
||||
|
||||
+4
-4
@@ -14,10 +14,10 @@
|
||||
│ ││ │ │
|
||||
│ ▸ Test ││ │ │
|
||||
│ ││ ◆ Coturn TURN server ──────────────────── │ │
|
||||
│ ▾ Servers ││ │ │
|
||||
│ ● example.org ││ Public IP address(es) │ │
|
||||
│ ││ › comma, separated, values │ │
|
||||
│ ││ │ │
|
||||
│ ▸ Host ││ │ │
|
||||
│ ││ Public IP address(es) │ │
|
||||
│ ▾ Servers ││ › comma, separated, values │ │
|
||||
│ ● example.org ││ │ │
|
||||
│ ││ │ │
|
||||
│ ││ ◆ Addresses ───────────────────────────── │ │
|
||||
│ ││ │ │
|
||||
|
||||
+4
-4
@@ -21,10 +21,10 @@
|
||||
│ ││ b Back up the database ? these keys │
|
||||
│ ▸ Test ││ s Backups ctrl+s save answers │
|
||||
│ ││ e Restore a backup ctrl+l layout: auto (wide) │
|
||||
│ ▾ Servers ││ z Roll back ctrl+y theme: interzone │
|
||||
│ ● example.org ││ D Disk space q quit, when not typing │
|
||||
│ ││ V Vacuum the database ctrl+c quit │
|
||||
│ ││ P Upgrade Postgres │
|
||||
│ ▸ Host ││ z Roll back ctrl+y theme: interzone │
|
||||
│ ││ D Disk space q quit, when not typing │
|
||||
│ ▾ Servers ││ V Vacuum the database ctrl+c quit │
|
||||
│ ● example.org ││ P Upgrade Postgres │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
|
||||
+4
-4
@@ -11,10 +11,10 @@
|
||||
│ ✗ example.org ││ ✗ example.org 1 failed, 1 warning │
|
||||
│ · matrix.org ││ Federation │
|
||||
│ ││ ✓ Delegation /.well-known/matrix/server sends servers to │
|
||||
│ ▾ Servers ││ matrix.example.org:443 │
|
||||
│ ● example.org ││ ✓ Federation API matrix.example.org:443 answers as example.org, with a trusted │
|
||||
│ ││ certificate │
|
||||
│ ││ ✓ Software Synapse 1.140.0 │
|
||||
│ ▸ Host ││ matrix.example.org:443 │
|
||||
│ ││ ✓ Federation API matrix.example.org:443 answers as example.org, with a trusted │
|
||||
│ ▾ Servers ││ certificate │
|
||||
│ ● example.org ││ ✓ Software Synapse 1.140.0 │
|
||||
│ ││ Clients │
|
||||
│ ││ ! Well-known https://example.org/.well-known/matrix/client sends apps to │
|
||||
│ ││ https://matrix.example.org, but without the CORS header web │
|
||||
|
||||
+2
-2
@@ -22,13 +22,13 @@
|
||||
│ ││ │
|
||||
│ ▸ Test ││ │
|
||||
│ ││ │
|
||||
│ ▸ Host ││ │
|
||||
│ ││ │
|
||||
│ ▾ Servers ││ │
|
||||
│ ● example.org ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ◫ auto (wide) ctrl+l ││ │
|
||||
│ ◐ interzone ctrl+y ││ │
|
||||
│ ◂ fold ctrl+b menu ││ │
|
||||
|
||||
+4
-4
@@ -21,10 +21,10 @@
|
||||
│ ││ │ Email alice@example.org │ │
|
||||
│ ▸ Test ││ │ Picture set │ │
|
||||
│ ││ │ │ │
|
||||
│ ▾ Servers ││ │ p new password a remove admin │ │
|
||||
│ ● example.org ││ │ s sign out everywhere d deactivate │ │
|
||||
│ ││ ╰────────────────────────────────────────────╯ │
|
||||
│ ││ │
|
||||
│ ▸ Host ││ │ p new password a remove admin │ │
|
||||
│ ││ │ s sign out everywhere d deactivate │ │
|
||||
│ ▾ Servers ││ ╰────────────────────────────────────────────╯ │
|
||||
│ ● example.org ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
|
||||
+4
-4
@@ -21,10 +21,10 @@
|
||||
│ ││ │ Email alice@example.org │ │
|
||||
│ ▸ Test ││ │ Picture set │ │
|
||||
│ ││ │ │ │
|
||||
│ ▾ Servers ││ │ p new password a remove admin s sign out everywhere d deactivate │ │
|
||||
│ ● example.org ││ ╰──────────────────────────────────────────────────────────────────────────────────────╯ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ▸ Host ││ │ p new password a remove admin s sign out everywhere d deactivate │ │
|
||||
│ ││ ╰──────────────────────────────────────────────────────────────────────────────────────╯ │
|
||||
│ ▾ Servers ││ │
|
||||
│ ● example.org ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
|
||||
+2
-2
@@ -21,14 +21,14 @@
|
||||
│ ││ ⇄ WhatsApp 1 account ▸ ╰────────────────────────────────────────────╯ │
|
||||
│ ▸ Test ││ │
|
||||
│ ││ │
|
||||
│ ▸ Host ││ │
|
||||
│ ││ │
|
||||
│ ▾ Servers ││ │
|
||||
│ ● example.org ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ││ │
|
||||
│ ◫ auto (wide) ctrl+l ││ │
|
||||
│ ◐ interzone ctrl+y ││ │
|
||||
│ ◂ fold ctrl+b menu ││ │
|
||||
|
||||
+4
-4
@@ -8,10 +8,10 @@
|
||||
│ ││ │
|
||||
│ ▸ Test ││ ▀█▀ █▄ █ ▀█▀ █▀▀ █▀█ ▀▀█ █▀█ █▄ █ █▀▀ │
|
||||
│ ││ █ █ ▀█ █ ██▄ █▀▄ ▄▀ █▄█ █ ▀█ ██▄ │
|
||||
│ ▾ Servers ││ │
|
||||
│ ● example.org ││ Your own Matrix server, set up with matrix-docker-ansible-deploy, │
|
||||
│ ││ without editing a single YAML file. │
|
||||
│ ││ │
|
||||
│ ▸ Host ││ │
|
||||
│ ││ Your own Matrix server, set up with matrix-docker-ansible-deploy, │
|
||||
│ ▾ Servers ││ without editing a single YAML file. │
|
||||
│ ● example.org ││ │
|
||||
│ ││ │
|
||||
│ ││ ╭─────────────────────────╮ ╭─────────────────────────╮ ╭──────────────────────────╮ │
|
||||
│ ││ │ ◆ Pick any homeserver │ │ ⊕ Opt into anything │ │ ⇅ Works in a blackout │ │
|
||||
|
||||
@@ -8,10 +8,10 @@
|
||||
│ ││ │
|
||||
│ ▸ Test ││ Your own Matrix server, set up with matrix-docker-ansible-deploy, │
|
||||
│ ││ without editing a single YAML file. │
|
||||
│ ▾ Servers ││ │
|
||||
│ ● example.org ││ │
|
||||
│ ││ ╭─────────────────────────╮ ╭─────────────────────────╮ ╭──────────────────────────╮ │
|
||||
│ ││ │ ◆ Pick any homeserver │ │ ⊕ Opt into anything │ │ ⇅ Works in a blackout │ │
|
||||
│ ▸ Host ││ │
|
||||
│ ││ │
|
||||
│ ▾ Servers ││ ╭─────────────────────────╮ ╭─────────────────────────╮ ╭──────────────────────────╮ │
|
||||
│ ● example.org ││ │ ◆ Pick any homeserver │ │ ⊕ Opt into anything │ │ ⇅ Works in a blackout │ │
|
||||
│ ││ │ │ │ │ │ │ │
|
||||
│ ││ │ Synapse, Continuwuity, │ │ 79 bridges, bots, │ │ Git, container, Docker, │ │
|
||||
│ ││ │ Tuwunel, Conduit or │ │ clients and services │ │ OS package and PyPI │ │
|
||||
|
||||
Reference in new issue
Block a user