HostServ: vhost request/approval flow

REQUEST <host> records a pending vhost (typed Option<PendingVhost> on the
account, VhostRequested/VhostRequestCleared events); operators review with
WAITING and either ACTIVATE (assign + apply to online sessions) or REJECT
(clear it). Host validation and the operator gate are shared with SET.
This commit is contained in:
Jean Chevronnet 2026-07-13 21:30:58 +00:00
parent 1227e26b95
commit 1edf250952
No known key found for this signature in database
8 changed files with 217 additions and 4 deletions

View file

@ -129,6 +129,8 @@ fn to_wire(entry: &LogEntry) -> Option<ReplicationEvent> {
| Event::AjoinRemoved { .. }
| Event::VhostSet { .. }
| Event::VhostDeleted { .. }
| Event::VhostRequested { .. }
| Event::VhostRequestCleared { .. }
| Event::AccountSuspended { .. }
| Event::AccountUnsuspended { .. }
| Event::MemoSent { .. }
@ -400,6 +402,7 @@ mod tests {
memos: vec![],
greet: String::new(),
vhost: None,
vhost_request: None,
};
let registered = LogEntry::for_test("A", 0, 1, Event::AccountRegistered(acct));
let wire = to_wire(&registered).expect("account registration replicates");