From cba4418be3eda206380b36fc97537bccaa65f85f Mon Sep 17 00:00:00 2001 From: rcourtman Date: Thu, 25 Dec 2025 23:58:24 +0000 Subject: [PATCH] fix: Remove Alpine from LXC template options Alpine uses apk/OpenRC instead of apt/systemd, which the Pulse LXC installation flow requires. This prevents failed installations. - Remove Alpine download option from advanced mode - Add note that Pulse requires Debian-based templates - Add validation when user selects from template list to catch Alpine/Gentoo/Arch/Void and fall back to Debian 12 with warning Related to #915 --- .../src/components/shared/ScrollableTable.tsx | 17 +++++++++++-- install.sh | 24 +++++++++++-------- 2 files changed, 29 insertions(+), 12 deletions(-) diff --git a/frontend-modern/src/components/shared/ScrollableTable.tsx b/frontend-modern/src/components/shared/ScrollableTable.tsx index 7e3a113e1..60adf6aff 100644 --- a/frontend-modern/src/components/shared/ScrollableTable.tsx +++ b/frontend-modern/src/components/shared/ScrollableTable.tsx @@ -1,10 +1,13 @@ -import { Component, JSX, createSignal, createEffect, onMount, onCleanup } from 'solid-js'; +import { Component, JSX, createSignal, createEffect, onMount, onCleanup, createMemo } from 'solid-js'; import { Show } from 'solid-js'; +import { useBreakpoint } from '@/hooks/useBreakpoint'; interface ScrollableTableProps { children: JSX.Element; class?: string; minWidth?: string; + /** Minimum width on mobile screens (< 768px). Defaults to '100%' for natural fit. */ + mobileMinWidth?: string; persistKey?: string; } @@ -15,6 +18,16 @@ export const ScrollableTable: Component = (props) => { const [showRightFade, setShowRightFade] = createSignal(false); let scrollContainer: HTMLDivElement | undefined; + const { isMobile } = useBreakpoint(); + + // Dynamic minWidth based on screen size + const effectiveMinWidth = createMemo(() => { + if (isMobile()) { + return props.mobileMinWidth ?? '100%'; + } + return props.minWidth || 'auto'; + }); + const checkScroll = (scrollLeftValue?: number) => { if (!scrollContainer) return; @@ -69,7 +82,7 @@ export const ScrollableTable: Component = (props) => { -
+
{props.children}
diff --git a/install.sh b/install.sh index 09b32c266..55e72b01d 100755 --- a/install.sh +++ b/install.sh @@ -1266,7 +1266,8 @@ create_lxc_container() { echo "Or download a new template:" echo " d) Download Debian 12 (recommended)" echo " u) Download Ubuntu 22.04 LTS" - echo " a) Download Alpine Linux (minimal)" + echo + echo "Note: Pulse requires a Debian-based template (apt/systemd)." echo safe_read_with_default "Select template number or option [Enter for Debian 12]: " template_choice "" if [[ -n "$template_choice" ]]; then @@ -1288,19 +1289,22 @@ create_lxc_container() { pveam download "$BEST_TEMPLATE_STORAGE" ubuntu-22.04-standard_22.04-1_amd64.tar.zst TEMPLATE="${BEST_TEMPLATE_STORAGE}:vztmpl/ubuntu-22.04-standard_22.04-1_amd64.tar.zst" ;; - a|A) - # Find best storage for templates (prefer one with most free space) - local BEST_TEMPLATE_STORAGE=$(pvesm status -content vztmpl 2>/dev/null | tail -n +2 | sort -k6 -rn | head -1 | awk '{print $1}') - BEST_TEMPLATE_STORAGE=${BEST_TEMPLATE_STORAGE:-$storage} - print_info "Downloading Alpine Linux to storage '$BEST_TEMPLATE_STORAGE'..." - pveam download "$BEST_TEMPLATE_STORAGE" alpine-3.18-default_20230607_amd64.tar.xz - TEMPLATE="${BEST_TEMPLATE_STORAGE}:vztmpl/alpine-3.18-default_20230607_amd64.tar.xz" - ;; [0-9]*) # Extract the full template path from numbered list TEMPLATE=$(echo -e "$ALL_TEMPLATES" | sed -n "${template_choice}p") if [[ -n "$TEMPLATE" ]]; then - print_info "Using template: $TEMPLATE" + # Check if selected template is Alpine or other non-Debian based + if [[ "$TEMPLATE" =~ alpine|gentoo|arch|void ]]; then + print_warn "Selected template ($TEMPLATE) is not Debian-based." + print_warn "Pulse LXC installation requires apt and systemd." + print_info "Falling back to Debian 12..." + local BEST_TEMPLATE_STORAGE=$(pvesm status -content vztmpl 2>/dev/null | tail -n +2 | sort -k6 -rn | head -1 | awk '{print $1}') + BEST_TEMPLATE_STORAGE=${BEST_TEMPLATE_STORAGE:-$storage} + ensure_debian_template + TEMPLATE="${BEST_TEMPLATE_STORAGE}:vztmpl/${DEBIAN_TEMPLATE}" + else + print_info "Using template: $TEMPLATE" + fi else # Find best storage for templates (prefer one with most free space) local BEST_TEMPLATE_STORAGE=$(pvesm status -content vztmpl 2>/dev/null | tail -n +2 | sort -k6 -rn | head -1 | awk '{print $1}')