IPv6-only broadband: 464XLAT city by city, a NAT64 pool next to CGNAT
A broadband city can swap its home routers for ones with a CLAT (ip6Go / ip6Stop, from the city panel's Home broadband). Over 30 to 180 days an even share of the homes moves each day, paid as the routers go in ($4 a home), waiting while cash is short; starting needs only the first day's share. New homes in a swapping or finished city get the new router at the same price. The panel says how many addresses it frees and what it does to the monthly IPv4 bill. ip4Use splits homes into public, behind CGNAT and IPv6-only: the NAT64 pool (ceil(IPv6-only homes / NAT64 ratio), 64/128/256, default 128) comes right after business blocks, before dual-stack homes. NAT64 gateways cost the same per Gbps of IPv4 as CGNAT boxes; NAT64 refunds sit under CGNAT's at the same ratio and never reach zero. The IPv4 share of home traffic is now a curve: 0.55 on day 0, two points less a year, floor 0.2. Out-of-space advice names the sharing left to stretch. Everything is under rule ip4; old saves load unchanged (no field means dual stack).
This commit is contained in:
parent
3bc1641a46
commit
69328ce257
25 changed files with 812 additions and 54 deletions
|
|
@ -88,9 +88,10 @@ const API_DOMAINS={
|
|||
pieSpatId:{table:'PIE_SPAT_DEF',kind:'key'},
|
||||
pieSpatChoice:{kind:'enum',values:[0,1]},
|
||||
countryCode:{kind:'enum',values:()=>[...new Set(CITIES.map(c=>c.cc))].sort()},
|
||||
// Address space: an IPv4 prefix length the market sells, and the CGNAT ratios.
|
||||
// Address space: an IPv4 prefix length the market sells, and the CGNAT and NAT64 ratios.
|
||||
ip4Len:{kind:'enum',values:()=>Array.from({length:IP4_MAX-IP4_MIN+1},(_,i)=>IP4_MIN+i)},
|
||||
ip4Ratio:{kind:'enum',values:()=>IP4_NAT.slice()},
|
||||
ip4Ratio64:{kind:'enum',values:()=>IP4_N64.slice()},
|
||||
scnId:{table:'SCN',kind:'id'},
|
||||
// A traceroute target in the modal's own terms.
|
||||
};
|
||||
|
|
|
|||
|
|
@ -315,7 +315,7 @@ const API_CMD={
|
|||
quote:a=>({setup:0,monthly:ip4InMo(Number(a.len)),blocked:[ip4On()?'':tr('ip4.off'),ip4On()&&ip4Full()?tr('ip4.too_many',{n:IP4_BLK}):''].filter(Boolean)}),
|
||||
doc:'Lease an IPv4 block of this prefix length by the month, at today\'s rate (fixed for the lease). Hand it back with ip4Return. Refused at 256 blocks, like ip4Buy.'},
|
||||
ip4Sell:{args:[['id','entityId']],confirm:'double',watch:['ip4'],
|
||||
doc:'Sell an owned block (not leased out) for 92% of the market price. Refused within two years of its last transfer, or when the customers signed would no longer fit with every home behind CGNAT.'},
|
||||
doc:'Sell an owned block (not leased out) for 92% of the market price. Refused within two years of its last transfer, or when the customers signed would no longer fit with every dual-stack home behind CGNAT and the IPv6-only homes in the NAT64 pool.'},
|
||||
ip4Out:{args:[['id','entityId']],watch:['ip4'],
|
||||
doc:'Lease an owned block out through a broker for a monthly income, while your own customers still fit without it.'},
|
||||
ip4Back:{args:[['id','entityId']],watch:['ip4'],
|
||||
|
|
@ -324,6 +324,13 @@ const API_CMD={
|
|||
doc:'Hand a leased-in block back, ending its monthly fee, when your customers still fit without it.'},
|
||||
ip4Nat:{args:[['v','ip4Ratio']],watch:['ip4'],
|
||||
doc:'Set how many broadband homes share one IPv4 address behind CGNAT (8, 16, 32 or 64). More frees space for business customers but more gamers ask for refunds; fewer is refused when the customers signed would not fit.'},
|
||||
ip4Nat64:{args:[['v','ip4Ratio64']],watch:['ip4'],
|
||||
doc:'Set how many IPv6-only homes share one IPv4 address in the NAT64 pool (64, 128 or 256). Their refunds are well under CGNAT\'s at the same ratio and shrink as the world moves to IPv6; fewer is refused when the customers signed would not fit.'},
|
||||
ip6Go:{args:[['city','cityId']],watch:['pops.#city'],
|
||||
quote:a=>({setup:ip6Cost(a.city),days:ip6Days(a.city),monthly:Math.round(ip6Mo(a.city,(R.rev&&R.rev.eyeballs)||0)),blocked:[ip6Why(a.city)].filter(Boolean)}),
|
||||
doc:'Take a broadband city IPv6-only (464XLAT): swap its dual-stack home routers for ones with a CLAT over the quoted days, paid day by day as they go in (setup is the whole swap; starting needs only the first day\'s share on hand, and it waits while cash is short). Those homes then need no IPv4 of their own, only a share of the NAT64 pool; new homes there get the new router too, at the swap\'s price a router, paid the day they join (even short of cash: a new home needs it). monthly is what it does to the IPv4 bill (NAT64 gateways and refunds against the CGNAT it saves; negative saves). Frees what the city panel says for new customers.'},
|
||||
ip6Stop:{args:[['city','cityId']],watch:['pops.#city'],
|
||||
doc:'Stop a city\'s swap to IPv6-only. The homes already swapped stay IPv6-only (their routers are paid for, nothing comes back); new homes come dual stack again. ip6Go resumes it for the rest.'},
|
||||
/* ---------- security, China, incidents ---------- */
|
||||
buildScrub:{args:[['city','cityId'],['tier','scrubTier',false]],watch:['scrubs'],
|
||||
quote:a=>{const T=SCRUB_TIERS[a.tier||0];return {setup:T?T.cost:undefined,monthly:T?T.mo:undefined};},
|
||||
|
|
@ -498,7 +505,7 @@ const API_CMD={
|
|||
|
||||
const API_VIEW={
|
||||
pieOpen:{args:[],doc:'Open Pie Control, the rocket company\'s panel.'},
|
||||
ip4Open:{args:[],doc:'Open the bank at its Address space section: your IPv4 blocks, who uses them, CGNAT and the transfer market.'},
|
||||
ip4Open:{args:[],doc:'Open the bank at its Address space section: your IPv4 blocks, who uses them, CGNAT, the NAT64 pool and the transfer market.'},
|
||||
ip4Pick:{args:[['v','ip4Len']],doc:'Pick the block size the Address space market quotes (a prefix length, 24 to 16).'},
|
||||
pieGovOpen:{args:[],doc:'Open the bank at its Government money section: the rocket company\'s fund auctions, the Pitcairn grant and the Ex-Im Pie Bank (it used to be Pie Control\'s Gov tab).'},
|
||||
pieTab:{args:[['t','pieTab']],doc:'Switch the Pie Control tab: traffic, co (the company, its books and the Founder\'s posts), fly (launches) or dish.'},
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ const API_STATE_DOC={
|
|||
t1v:{type:'integer',doc:'Level at which Tier 1 transit was offered.'},
|
||||
auV:{type:'integer',doc:'Australia content level gate.'},
|
||||
seen:{type:'array',doc:'Network ids the deals panel has already shown. Vestigial: written by newGame, read nowhere.'},
|
||||
pops:{type:'map',doc:'Your POPs by city id: day opened, broadband (bb), ad boost, downtime, routers, generator, second site, teleport (tele: 1 GEO dishes, 2 with MEO tracking antennas).'},
|
||||
pops:{type:'map',doc:'Your POPs by city id: day opened, broadband (bb: d, its demand in Gbps; v6, the share of its homes that are IPv6-only behind NAT64, absent for dual stack; v6e, the day a swap to IPv6-only finishes, while it runs), ad boost, downtime, routers, generator, second site, teleport (tele: 1 GEO dishes, 2 with MEO tracking antennas).'},
|
||||
links:{type:'array',doc:'Your links: waves, dark fiber (df), own cables, fabric circuits (vxc), express lightpaths (xp: via lists the dark fibers it rides from a, ch its optics) and rented satellite circuits (sat: bird, g Gbps, km of radio path, ready day), each with an entity id.'},
|
||||
transit:{type:'array',doc:'Transit ports: city, net, tier, LAG members, port history for 95th-percentile billing.'},
|
||||
ixp:{type:'map',doc:'IX ports by exchange city; tier per port (may exceed 1 with LAG members in ixn).'},
|
||||
|
|
@ -61,7 +61,7 @@ const API_STATE_DOC={
|
|||
ops:{type:'map',doc:'The NOC intern: who is hired, each standing order\'s on/off switch and settings (network work only: deals belong to the sales desk, slAuto), the monthly budget and what it spent, per-POP exceptions, the new-POP template and the weekly log.'},
|
||||
core:{type:'map',doc:'Your backbone technology: lv bought, the level it runs at, the interop lab.'},
|
||||
ddosAuto:{type:'map',doc:'The NOC\'s auto-mitigation switches: rtbh and scrub.'},
|
||||
ip4:{type:'map',doc:'IPv4 address space (rule ip4): b, the blocks, at most 256 (len: prefix length 16-24, k: rir from the registry, buy bought, in leased in; d: the day it last moved, out: leased out, mo: the monthly fee or income), nat: homes per address behind CGNAT, w: which warnings were shown. What customers use is derived from their kind and size.'},
|
||||
ip4:{type:'map',doc:'IPv4 address space (rule ip4): b, the blocks, at most 256 (len: prefix length 16-24, k: rir from the registry, buy bought, in leased in; d: the day it last moved, out: leased out, mo: the monthly fee or income), nat: homes per address behind CGNAT, n64: IPv6-only homes per address in the NAT64 pool, w: which warnings were shown. What customers use is derived from their kind and size.'},
|
||||
popStd:{type:'map',doc:'The build standard, or null for none. g router model (an RG index), rt routers, then only the targets that are set: site2, gen (true), lag (2 or 4 members), split, ix (true), pni (2 or 3 cities per network), sys (roadm, cl), opt (fast), wv (an LT index). New POPs get g, rt, site2 and gen at once; the std standing order and bstdApply bring the rest up. g and sys are also the model the routers order and the line system the optup order standardize on.'},
|
||||
mp:{type:'map',doc:'Multiplayer, only in a self-hosted copy with a session server: the session code, your player id, the AS number and seed the session gave you, its rules preset, your colour, its title and the last save number the server holds; null in every other game.'},
|
||||
demo:{type:'map',doc:'Vendor demo units on order, by "kind:id" → ready day.'},
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue