Closed SomeoneWeird closed 3 weeks ago
This adds web APIs for system installation.
GET /system/bootstrap is modified to return a new setupFact named installationMode.
GET /system/bootstrap
setupFact
installationMode
{ "assets": {}, "states": {}, "stats": {}, "setupFacts": { "installationMode": "canInstall", ... } }
There are 4 modes that can be returned:
isInstalled
cannotInstall
mustInstall
canInstall
A new GET /system/install/disks is added that returns a list of possible disk-installation targets:
GET /system/install/disks
➜ http 127.0.0.1:3000/system/install/disks [ { "Name": "/dev/vdb", "Size": 8796093022208, "SizePretty": "8.00 TB" } ]
A new POST /system/install call is added that actually performs the system installation. It expects a body of:
POST /system/install
{ "disk": "/dev/vdb", "secret": "yes-i-will-destroy-everything-on-this-disk" }
This adds web APIs for system installation.
GET /system/bootstrap
is modified to return a newsetupFact
namedinstallationMode
.There are 4 modes that can be returned:
isInstalled
: This means that the box has already been installed.cannotInstall
: This occurs when the box has already been set up.mustInstall
: The user is booting off read-only media and MUST install to continue use.canInstall
: The user is booting off read-write media, and installation is optional to another disk.A new
GET /system/install/disks
is added that returns a list of possible disk-installation targets:A new
POST /system/install
call is added that actually performs the system installation. It expects a body of: