Skip to content

Commit 38ea7db

Browse files
committed
fix: always show SSH access dialog in advanced settings
- SSH access dialog is now always displayed regardless of password or SSH keys - Added step indicator to SSH settings dialogs for consistency - configure_ssh_settings() now accepts optional step_info parameter - Updated documentation for SSH configuration functions Fixes #9753
1 parent 1cae72b commit 38ea7db

File tree

3 files changed

+234
-126
lines changed

3 files changed

+234
-126
lines changed

docs/misc/build.func/BUILD_FUNC_ENVIRONMENT_VARIABLES.md

Lines changed: 80 additions & 73 deletions
Original file line numberDiff line numberDiff line change
@@ -8,103 +8,103 @@ This document provides a comprehensive reference of all environment variables us
88

99
### Core Container Variables
1010

11-
| Variable | Description | Default | Set In | Used In |
12-
|----------|-------------|---------|---------|---------|
13-
| `APP` | Application name (e.g., "plex", "nextcloud") | - | Environment | Throughout |
14-
| `NSAPP` | Namespace application name | `$APP` | Environment | Throughout |
15-
| `CTID` | Container ID | - | Environment | Container creation |
16-
| `CT_TYPE` | Container type ("install" or "update") | "install" | Environment | Entry point |
17-
| `CT_NAME` | Container name | `$APP` | Environment | Container creation |
11+
| Variable | Description | Default | Set In | Used In |
12+
| --------- | -------------------------------------------- | --------- | ----------- | ------------------ |
13+
| `APP` | Application name (e.g., "plex", "nextcloud") | - | Environment | Throughout |
14+
| `NSAPP` | Namespace application name | `$APP` | Environment | Throughout |
15+
| `CTID` | Container ID | - | Environment | Container creation |
16+
| `CT_TYPE` | Container type ("install" or "update") | "install" | Environment | Entry point |
17+
| `CT_NAME` | Container name | `$APP` | Environment | Container creation |
1818

1919
### Operating System Variables
2020

21-
| Variable | Description | Default | Set In | Used In |
22-
|----------|-------------|---------|---------|---------|
23-
| `var_os` | Operating system selection | "debian" | base_settings() | OS selection |
24-
| `var_version` | OS version | "12" | base_settings() | Template selection |
25-
| `var_template` | Template name | Auto-generated | base_settings() | Template download |
21+
| Variable | Description | Default | Set In | Used In |
22+
| -------------- | -------------------------- | -------------- | --------------- | ------------------ |
23+
| `var_os` | Operating system selection | "debian" | base_settings() | OS selection |
24+
| `var_version` | OS version | "12" | base_settings() | Template selection |
25+
| `var_template` | Template name | Auto-generated | base_settings() | Template download |
2626

2727
### Resource Configuration Variables
2828

29-
| Variable | Description | Default | Set In | Used In |
30-
|----------|-------------|---------|---------|---------|
31-
| `var_cpu` | CPU cores | "2" | base_settings() | Container creation |
32-
| `var_ram` | RAM in MB | "2048" | base_settings() | Container creation |
33-
| `var_disk` | Disk size in GB | "8" | base_settings() | Container creation |
34-
| `DISK_SIZE` | Disk size (alternative) | `$var_disk` | Environment | Container creation |
35-
| `CORE_COUNT` | CPU cores (alternative) | `$var_cpu` | Environment | Container creation |
36-
| `RAM_SIZE` | RAM size (alternative) | `$var_ram` | Environment | Container creation |
29+
| Variable | Description | Default | Set In | Used In |
30+
| ------------ | ----------------------- | ----------- | --------------- | ------------------ |
31+
| `var_cpu` | CPU cores | "2" | base_settings() | Container creation |
32+
| `var_ram` | RAM in MB | "2048" | base_settings() | Container creation |
33+
| `var_disk` | Disk size in GB | "8" | base_settings() | Container creation |
34+
| `DISK_SIZE` | Disk size (alternative) | `$var_disk` | Environment | Container creation |
35+
| `CORE_COUNT` | CPU cores (alternative) | `$var_cpu` | Environment | Container creation |
36+
| `RAM_SIZE` | RAM size (alternative) | `$var_ram` | Environment | Container creation |
3737

3838
### Network Configuration Variables
3939

40-
| Variable | Description | Default | Set In | Used In |
41-
|----------|-------------|---------|---------|---------|
42-
| `var_net` | Network interface | "vmbr0" | base_settings() | Network config |
43-
| `var_bridge` | Bridge interface | "vmbr0" | base_settings() | Network config |
44-
| `var_gateway` | Gateway IP | "192.168.1.1" | base_settings() | Network config |
45-
| `var_ip` | Container IP address | - | User input | Network config |
46-
| `var_ipv6` | IPv6 address | - | User input | Network config |
47-
| `var_vlan` | VLAN ID | - | User input | Network config |
48-
| `var_mtu` | MTU size | "1500" | base_settings() | Network config |
49-
| `var_mac` | MAC address | Auto-generated | base_settings() | Network config |
50-
| `NET` | Network interface (alternative) | `$var_net` | Environment | Network config |
51-
| `BRG` | Bridge interface (alternative) | `$var_bridge` | Environment | Network config |
52-
| `GATE` | Gateway IP (alternative) | `$var_gateway` | Environment | Network config |
53-
| `IPV6_METHOD` | IPv6 configuration method | "none" | Environment | Network config |
54-
| `VLAN` | VLAN ID (alternative) | `$var_vlan` | Environment | Network config |
55-
| `MTU` | MTU size (alternative) | `$var_mtu` | Environment | Network config |
56-
| `MAC` | MAC address (alternative) | `$var_mac` | Environment | Network config |
40+
| Variable | Description | Default | Set In | Used In |
41+
| ------------- | ------------------------------- | -------------- | --------------- | -------------- |
42+
| `var_net` | Network interface | "vmbr0" | base_settings() | Network config |
43+
| `var_bridge` | Bridge interface | "vmbr0" | base_settings() | Network config |
44+
| `var_gateway` | Gateway IP | "192.168.1.1" | base_settings() | Network config |
45+
| `var_ip` | Container IP address | - | User input | Network config |
46+
| `var_ipv6` | IPv6 address | - | User input | Network config |
47+
| `var_vlan` | VLAN ID | - | User input | Network config |
48+
| `var_mtu` | MTU size | "1500" | base_settings() | Network config |
49+
| `var_mac` | MAC address | Auto-generated | base_settings() | Network config |
50+
| `NET` | Network interface (alternative) | `$var_net` | Environment | Network config |
51+
| `BRG` | Bridge interface (alternative) | `$var_bridge` | Environment | Network config |
52+
| `GATE` | Gateway IP (alternative) | `$var_gateway` | Environment | Network config |
53+
| `IPV6_METHOD` | IPv6 configuration method | "none" | Environment | Network config |
54+
| `VLAN` | VLAN ID (alternative) | `$var_vlan` | Environment | Network config |
55+
| `MTU` | MTU size (alternative) | `$var_mtu` | Environment | Network config |
56+
| `MAC` | MAC address (alternative) | `$var_mac` | Environment | Network config |
5757

5858
### Storage Configuration Variables
5959

60-
| Variable | Description | Default | Set In | Used In |
61-
|----------|-------------|---------|---------|---------|
62-
| `var_template_storage` | Storage for templates | - | select_storage() | Template storage |
63-
| `var_container_storage` | Storage for container disks | - | select_storage() | Container storage |
64-
| `TEMPLATE_STORAGE` | Template storage (alternative) | `$var_template_storage` | Environment | Template storage |
65-
| `CONTAINER_STORAGE` | Container storage (alternative) | `$var_container_storage` | Environment | Container storage |
60+
| Variable | Description | Default | Set In | Used In |
61+
| ----------------------- | ------------------------------- | ------------------------ | ---------------- | ----------------- |
62+
| `var_template_storage` | Storage for templates | - | select_storage() | Template storage |
63+
| `var_container_storage` | Storage for container disks | - | select_storage() | Container storage |
64+
| `TEMPLATE_STORAGE` | Template storage (alternative) | `$var_template_storage` | Environment | Template storage |
65+
| `CONTAINER_STORAGE` | Container storage (alternative) | `$var_container_storage` | Environment | Container storage |
6666

6767
### Feature Flags
6868

69-
| Variable | Description | Default | Set In | Used In |
70-
|----------|-------------|---------|---------|---------|
71-
| `ENABLE_FUSE` | Enable FUSE support | "true" | base_settings() | Container features |
72-
| `ENABLE_TUN` | Enable TUN/TAP support | "true" | base_settings() | Container features |
73-
| `ENABLE_KEYCTL` | Enable keyctl support | "true" | base_settings() | Container features |
74-
| `ENABLE_MOUNT` | Enable mount support | "true" | base_settings() | Container features |
75-
| `ENABLE_NESTING` | Enable nesting support | "false" | base_settings() | Container features |
76-
| `ENABLE_PRIVILEGED` | Enable privileged mode | "false" | base_settings() | Container features |
77-
| `ENABLE_UNPRIVILEGED` | Enable unprivileged mode | "true" | base_settings() | Container features |
78-
| `VERBOSE` | Enable verbose output | "false" | Environment | Logging |
79-
| `SSH` | Enable SSH key provisioning | "true" | base_settings() | SSH setup |
69+
| Variable | Description | Default | Set In | Used In |
70+
| --------------------- | --------------------------- | ------- | --------------- | ------------------ |
71+
| `ENABLE_FUSE` | Enable FUSE support | "true" | base_settings() | Container features |
72+
| `ENABLE_TUN` | Enable TUN/TAP support | "true" | base_settings() | Container features |
73+
| `ENABLE_KEYCTL` | Enable keyctl support | "true" | base_settings() | Container features |
74+
| `ENABLE_MOUNT` | Enable mount support | "true" | base_settings() | Container features |
75+
| `ENABLE_NESTING` | Enable nesting support | "false" | base_settings() | Container features |
76+
| `ENABLE_PRIVILEGED` | Enable privileged mode | "false" | base_settings() | Container features |
77+
| `ENABLE_UNPRIVILEGED` | Enable unprivileged mode | "true" | base_settings() | Container features |
78+
| `VERBOSE` | Enable verbose output | "false" | Environment | Logging |
79+
| `SSH` | Enable SSH key provisioning | "true" | base_settings() | SSH setup |
8080

8181
### GPU Passthrough Variables
8282

83-
| Variable | Description | Default | Set In | Used In |
84-
|----------|-------------|---------|---------|---------|
85-
| `GPU_APPS` | List of apps that support GPU | - | Environment | GPU detection |
86-
| `var_gpu` | GPU selection | - | User input | GPU passthrough |
87-
| `var_gpu_type` | GPU type (intel/amd/nvidia) | - | detect_gpu_devices() | GPU passthrough |
88-
| `var_gpu_devices` | GPU device list | - | detect_gpu_devices() | GPU passthrough |
83+
| Variable | Description | Default | Set In | Used In |
84+
| ----------------- | ----------------------------- | ------- | -------------------- | --------------- |
85+
| `GPU_APPS` | List of apps that support GPU | - | Environment | GPU detection |
86+
| `var_gpu` | GPU selection | - | User input | GPU passthrough |
87+
| `var_gpu_type` | GPU type (intel/amd/nvidia) | - | detect_gpu_devices() | GPU passthrough |
88+
| `var_gpu_devices` | GPU device list | - | detect_gpu_devices() | GPU passthrough |
8989

9090
### API and Diagnostics Variables
9191

92-
| Variable | Description | Default | Set In | Used In |
93-
|----------|-------------|---------|---------|---------|
94-
| `DIAGNOSTICS` | Enable diagnostics mode | "false" | Environment | Diagnostics |
95-
| `METHOD` | Installation method | "install" | Environment | Installation flow |
96-
| `RANDOM_UUID` | Random UUID for tracking | - | Environment | Logging |
97-
| `API_TOKEN` | Proxmox API token | - | Environment | API calls |
98-
| `API_USER` | Proxmox API user | - | Environment | API calls |
92+
| Variable | Description | Default | Set In | Used In |
93+
| ------------- | ------------------------ | --------- | ----------- | ----------------- |
94+
| `DIAGNOSTICS` | Enable diagnostics mode | "false" | Environment | Diagnostics |
95+
| `METHOD` | Installation method | "install" | Environment | Installation flow |
96+
| `RANDOM_UUID` | Random UUID for tracking | - | Environment | Logging |
97+
| `API_TOKEN` | Proxmox API token | - | Environment | API calls |
98+
| `API_USER` | Proxmox API user | - | Environment | API calls |
9999

100100
### Settings Persistence Variables
101101

102-
| Variable | Description | Default | Set In | Used In |
103-
|----------|-------------|---------|---------|---------|
104-
| `SAVE_DEFAULTS` | Save settings as defaults | "false" | User input | Settings persistence |
105-
| `SAVE_APP_DEFAULTS` | Save app-specific defaults | "false" | User input | Settings persistence |
106-
| `DEFAULT_VARS_FILE` | Path to default.vars | "/usr/local/community-scripts/default.vars" | Environment | Settings persistence |
107-
| `APP_DEFAULTS_FILE` | Path to app.vars | "/usr/local/community-scripts/defaults/$APP.vars" | Environment | Settings persistence |
102+
| Variable | Description | Default | Set In | Used In |
103+
| ------------------- | -------------------------- | ------------------------------------------------- | ----------- | -------------------- |
104+
| `SAVE_DEFAULTS` | Save settings as defaults | "false" | User input | Settings persistence |
105+
| `SAVE_APP_DEFAULTS` | Save app-specific defaults | "false" | User input | Settings persistence |
106+
| `DEFAULT_VARS_FILE` | Path to default.vars | "/usr/local/community-scripts/default.vars" | Environment | Settings persistence |
107+
| `APP_DEFAULTS_FILE` | Path to app.vars | "/usr/local/community-scripts/defaults/$APP.vars" | Environment | Settings persistence |
108108

109109
## Variable Precedence Chain
110110

@@ -152,6 +152,7 @@ export SSH="true"
152152
## Environment Variable Usage Patterns
153153

154154
### 1. Container Creation
155+
155156
```bash
156157
# Basic container creation
157158
export APP="nextcloud"
@@ -170,6 +171,7 @@ export var_container_storage="local"
170171
```
171172

172173
### 2. GPU Passthrough
174+
173175
```bash
174176
# Enable GPU passthrough
175177
export GPU_APPS="plex,jellyfin,emby"
@@ -178,6 +180,7 @@ export ENABLE_PRIVILEGED="true"
178180
```
179181

180182
### 3. Advanced Network Configuration
183+
181184
```bash
182185
# VLAN and IPv6 configuration
183186
export var_vlan="100"
@@ -187,6 +190,7 @@ export var_mtu="9000"
187190
```
188191

189192
### 4. Storage Configuration
193+
190194
```bash
191195
# Custom storage locations
192196
export var_template_storage="nfs-storage"
@@ -206,6 +210,7 @@ The script validates variables at several points:
206210
## Common Variable Combinations
207211

208212
### Development Container
213+
209214
```bash
210215
export APP="dev-container"
211216
export CTID="200"
@@ -220,6 +225,7 @@ export ENABLE_PRIVILEGED="true"
220225
```
221226

222227
### Media Server with GPU
228+
223229
```bash
224230
export APP="plex"
225231
export CTID="300"
@@ -235,6 +241,7 @@ export ENABLE_PRIVILEGED="true"
235241
```
236242

237243
### Lightweight Service
244+
238245
```bash
239246
export APP="nginx"
240247
export CTID="400"

0 commit comments

Comments
 (0)