# Setup Wizard Interactive bootstrap for Debian-based VM templates. The wizard is safe to re-run and is designed for Proxmox clones that need the same base hardening, tooling, and share mounts before they enter service. ## Files - `bootstrap.sh` – convenience wrapper you drop on the template. It escalates to root, pulls the latest wizard, and executes it. - `setup.sh` – primary script. Uses `whiptail` menus to configure the VM. ## Requirements - Debian 12/13 guest with network access to `git.jordanwages.com`. - Either `curl` or `wget`. The wizard auto-installs `whiptail` if it is missing. - Ability to escalate to root (`sudo`, root shell, or root password). ## Running The Wizard 1. Place `bootstrap.sh` on the template (or use the `curl | bash` one-liner in the main README). 2. Execute `sudo ./bootstrap.sh` (or simply `./bootstrap.sh` as root). 3. Follow the `whiptail` prompts. You can cancel at any step; no changes are committed until each section completes. You can re-run `setup.sh` at any time to reapply updates, rotate keys, or adjust NAS mounts. The managed sections overwrite prior state so the machine always matches the latest answers. ## What The Wizard Configures - **Core packages**: installs `sudo`, `curl`, `gnupg`, `lsb-release`, `nfs-common`, and any optional tools you choose (`htop`, `jq`, `git`, etc.). - **System updates**: full `apt-get dist-upgrade` with a progress gauge. - **Sudo access**: toggles passwordless sudo for any non-system users on the box. - **Hostname**: updates `/etc/hosts` and `hostnamectl` - **SSH keys**: overwrites `authorized_keys` for `root` and the primary user (`jordanwages` by default) after deduplicating entries. - **Shell quality-of-life**: installs bat/ncdu aliases and replaces `neofetch` with `fastfetch` for login banners. - **NFS mounts**: manages a comment-delimited block in `/etc/fstab` for the NAS hosts you select and attempts to mount them immediately. - **Logging**: tee'd transcript stored at `/var/log/freshbox.log` on each run. ## Customization - **Default SSH key**: edit `DEFAULT_SSH_KEY` near the top of `setup.sh` to your preferred public key. - **Optional packages**: expand the `TOOLS=(...)` array; everything listed appears as a checkbox in the “Extra Utilities” menu. - **NAS hosts**: change the `NFS_HOSTS=(...)` array to match your environment. Each value becomes a selectable share under `/media/`. - **Primary user**: adjust `USER_NAME` if your golden image uses a different account than `jordanwages`. ## Troubleshooting - Wizard aborts with missing `whiptail`: rerun the script; it self-installs `whiptail` before launching menus. - NFS mounts fail: the wizard leaves a ⚠️ note in the final dialog. Check `/var/log/freshbox.log` for the mount error and re-run once networking or permissions are fixed. - Need to inspect actions: review `/var/log/freshbox.log`, which captures command output from the session.