code wiki / _hdl_build / nx_hostdeploy.nx
nx_hostdeploy.nx
buildroot/runtime/_hdl_build/nx_hostdeploy.nx
about
nx_hostdeploy.nx -- sovereign deploy of the S-class hosting stack to the NAS. Streams 4 artifacts over
the team's OWN SSH (no scp): the router daemon -> sites.elf.new, sites.conf -> sites.conf.new, the
andelinwest legal page -> andelinwest_index.html.new, and the sovereign control plane -> nx_hostctl.
Then launches `nx_hostctl takeover` -- which does ALL the logic in Nishi (proc-kill the old .sh
supervisor + daemon, atomic sys_renameat publish, become the sovereign supervisor). The only shell is
the one-time chmod+x + setsid launch of the sovereign binary (the daemon-start bootstrap). Password from
/tmp/nxpw (staged + deleted by the runner). license_tier: ORIGINAL
dependencies 2 imports · 0 importers
imports: nx_syscalls.nxnx_ssh_lib.nx
imported by: nobody (leaf or entry point)
call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown
structs
| none |
consts
| 10 | const K_MAGIC_65536: i64 = 65536 |
| 11 | const K_MAGIC_1048576: i64 = 1048576 |
| 12 | const K_MAGIC_16384: i64 = 16384 |
| 13 | const K_MAGIC_1024: i64 = 1024 |
functions
| 15 | func slen(s: *u8) -> i64 { var n: i64=0; while s[n]!=0 as u8 { n=n+1 } return n } called by 1: main |
| 16 | func ssh_putn(v: i64) -> i64 { let b: *u8=sys_mmap(28); var m: i64=v; let t: *u8=sys_mmap(28); var k: i64=0; if m==0{t[0]=48;k=1}; while m>0{t[k]=(48+(m%10)) as u8;m=m/10;k=k+1}; var i: i64=0; while i<k{b[i]=t[k-1-i];i=i+1}; sys_write(2,b,k); return 0 } |
| 21 | func ssh_drain(st: *SshState) -> i64 |
| 35 | func ssh_put_file(st: *SshState, wcmd: *u8, wcmdlen: i64, data: *u8, datalen: i64) -> i64 |
| 81 | func rd(path: *u8, lenout: *i64) -> *u8 |
| 86 | func main() -> i64 |