feat: Add default and advanced install method selection
- Add ConfigurationModal component for selecting default or advanced installation mode - Default mode: Uses predefined defaults with minimal user input (hostname from slug, vmbr0, dhcp, etc.) - Advanced mode: Full configuration modal with all environment variables customizable - Add support for IPv4 CIDR input when network mode is 'static' - Add support for IPv6 static address input when IPv6 method is 'static' - Implement password formatting as '-password <password>' for build.func compatibility - Auto-enable SSH when password or SSH keys are provided - Add storage selection dropdowns filtered by server node assignment - Pass environment variables through entire execution stack (frontend -> WebSocket -> SSH/local execution) - Add mode environment variable (always set to 'default' for script execution) - Update ExecutionModeModal to show 'Advanced (Beta)' option
This commit is contained in:
@@ -82,6 +82,7 @@ const handle = app.getRequestHandler();
|
||||
* @property {number} [cloneCount]
|
||||
* @property {string[]} [hostnames]
|
||||
* @property {'lxc'|'vm'} [containerType]
|
||||
* @property {Record<string, string|number|boolean>} [envVars]
|
||||
*/
|
||||
|
||||
class ScriptExecutionHandler {
|
||||
@@ -421,7 +422,9 @@ class ScriptExecutionHandler {
|
||||
// Add envVars to environment
|
||||
if (envVars && typeof envVars === 'object') {
|
||||
for (const [key, value] of Object.entries(envVars)) {
|
||||
envWithVars[key] = String(value);
|
||||
/** @type {Record<string, string>} */
|
||||
const envRecord = envWithVars;
|
||||
envRecord[key] = String(value);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user