fix(vm): Fix ARM builds by using arch-specific packages

- Remove docker/bind-server from ARM (not available)
- Use simpler package set for ARM targets
- Fix rockchip profile name
- Keep x86-64 with full package set

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
CyberMind-FR 2026-03-17 21:17:46 +01:00
parent 9c4d8dcdfd
commit eb46c7128b
4 changed files with 18 additions and 99 deletions

View File

@ -580,7 +580,9 @@
"Bash(gh workflow run:*)",
"Bash(git show:*)",
"Bash(jq -r '.[] | \"\" \"\" + .workflowName + \"\": \"\" + .conclusion + \"\" \\(ID: \"\" + \\(.databaseId | tostring\\) + \"\"\\)\"\"' echo \"\" echo \"=== VM Appliance Artifacts ===\" gh api repos/gkerma/secubox-openwrt/actions/runs/23205786221/artifacts --jq '.artifacts[] | \"\" \"\" + .name + \"\" \\(\"\" + \\(\\(.size_in_bytes / 1048576\\) | floor | tostring\\) + \"\" MB\\)\"\"' echo \"\" echo \"=== Package Build Artifacts ===\" gh api repos/gkerma/secubox-openwrt/actions/runs/23206423503/artifacts --jq '.artifacts[] | \"\" \"\" + .name + \"\" \\(\"\" + \\(\\(.size_in_bytes / 1048576\\) | floor | tostring\\) + \"\" MB\\)\"\"')",
"Bash(__NEW_LINE_0593582cd60ca850__ echo \"\")"
"Bash(__NEW_LINE_0593582cd60ca850__ echo \"\")",
"Bash(./secubox-tools/c3box-vm-full-build.sh:*)",
"Bash(DISK_SIZE=2 OUTPUT_DIR=/home/reepost/CyberMindStudio/secubox-openwrt/secubox-tools/c3box-vm/output ./secubox-tools/c3box-vm-full-build.sh:*)"
]
}
}

View File

@ -599,26 +599,29 @@ jobs:
cat repositories.conf
fi
# Base OpenWrt packages
# Base OpenWrt packages (common to all architectures)
PACKAGES="luci luci-ssl luci-app-opkg luci-theme-openwrt-2020"
PACKAGES="$PACKAGES curl wget-ssl htop iftop tcpdump nano"
PACKAGES="$PACKAGES openssh-sftp-server"
PACKAGES="$PACKAGES block-mount kmod-fs-ext4 kmod-fs-vfat kmod-fs-btrfs"
PACKAGES="$PACKAGES parted e2fsprogs resize2fs"
PACKAGES="$PACKAGES block-mount kmod-fs-ext4 kmod-fs-vfat"
PACKAGES="$PACKAGES git rsync screen tmux bash jq"
PACKAGES="$PACKAGES docker dockerd containerd"
PACKAGES="$PACKAGES wireguard-tools kmod-wireguard luci-proto-wireguard"
# Remove conflicting dnsmasq
PACKAGES="$PACKAGES -dnsmasq dnsmasq-full"
# Network and security packages
PACKAGES="$PACKAGES haproxy bind-server bind-tools"
PACKAGES="$PACKAGES kmod-nf-conntrack kmod-nf-nat kmod-ipt-nat"
# Network packages (available on all platforms)
PACKAGES="$PACKAGES haproxy"
# Architecture-specific packages
case "${{ matrix.target }}" in
x86/64)
# x86-64 has the most packages available
PACKAGES="$PACKAGES parted e2fsprogs resize2fs"
PACKAGES="$PACKAGES kmod-fs-btrfs"
PACKAGES="$PACKAGES docker dockerd containerd"
PACKAGES="$PACKAGES bind-server bind-tools"
PACKAGES="$PACKAGES kmod-nf-conntrack kmod-nf-nat kmod-ipt-nat"
if [[ "${{ matrix.boot }}" == "efi" ]]; then
PACKAGES="$PACKAGES grub2-efi"
fi
@ -627,14 +630,17 @@ jobs:
armsr/armv8)
# ARM64 generic - virtio support for QEMU/Proxmox
PACKAGES="$PACKAGES kmod-virtio-net kmod-virtio-blk"
PACKAGES="$PACKAGES parted e2fsprogs"
;;
bcm27xx/bcm2711)
# Raspberry Pi 4 specific
PACKAGES="$PACKAGES kmod-usb-net-asix-ax88179 kmod-usb-net-rtl8152"
PACKAGES="$PACKAGES parted e2fsprogs"
;;
rockchip/armv8)
# Rockchip ARM64
PACKAGES="$PACKAGES kmod-usb-net-rtl8152"
PACKAGES="$PACKAGES parted e2fsprogs"
;;
esac
@ -703,8 +709,8 @@ jobs:
PROFILE="rpi-4"
;;
rockchip/armv8)
# List available profiles and pick first one
PROFILE=$(make info 2>/dev/null | grep -oP 'Default profile:\s+\K\S+' || echo "nanopi-r4s")
# NanoPi R4S as default for rockchip
PROFILE="friendlyarm_nanopi-r4s"
;;
*)
PROFILE="generic"

View File

@ -1,89 +0,0 @@
#!/bin/bash
#
# proxmox-import.sh - Import SecuBox VM into Proxmox VE
#
# Usage: ./proxmox-import.sh [VMID] [STORAGE] [QCOW2_FILE]
#
# Examples:
# ./proxmox-import.sh 200 local-lvm
# ./proxmox-import.sh 201 local-zfs C3Box-SecuBox.qcow2
#
set -e
VMID="${1:-200}"
STORAGE="${2:-local-lvm}"
QCOW2_FILE="${3:-C3Box-SecuBox.qcow2}"
# Colors
GREEN='\033[0;32m'
BLUE='\033[0;34m'
NC='\033[0m'
echo -e "${BLUE}SecuBox VM Import for Proxmox VE${NC}"
echo "=================================="
echo ""
echo "VMID: $VMID"
echo "Storage: $STORAGE"
echo "Image: $QCOW2_FILE"
echo ""
# Check if file exists
if [ ! -f "$QCOW2_FILE" ]; then
echo "Error: QCOW2 file not found: $QCOW2_FILE"
exit 1
fi
# Check if qm command exists
if ! command -v qm &>/dev/null; then
echo "Error: qm command not found. Are you running this on Proxmox?"
exit 1
fi
# Check if VMID already exists
if qm status $VMID &>/dev/null; then
echo "Error: VM $VMID already exists. Choose a different VMID."
exit 1
fi
echo "Creating VM $VMID..."
# Create VM with basic settings
qm create $VMID \
--name c3box-secubox \
--memory 2048 \
--cores 2 \
--cpu host \
--net0 virtio,bridge=vmbr0 \
--ostype l26 \
--agent enabled=1
echo "Importing disk..."
# Import disk
qm importdisk $VMID "$QCOW2_FILE" $STORAGE --format qcow2
echo "Attaching disk..."
# Attach disk with VirtIO SCSI
qm set $VMID \
--scsihw virtio-scsi-pci \
--scsi0 $STORAGE:vm-$VMID-disk-0
# Set boot order
qm set $VMID --boot order=scsi0
# Add serial console for troubleshooting
qm set $VMID --serial0 socket
echo ""
echo -e "${GREEN}VM $VMID created successfully!${NC}"
echo ""
echo "Next steps:"
echo " 1. Start VM: qm start $VMID"
echo " 2. Open console: qm terminal $VMID"
echo " 3. Get IP: qm guest cmd $VMID network-get-interfaces"
echo " 4. Web UI: https://<vm-ip>"
echo ""
echo "Default credentials: root / c3box"
echo "IMPORTANT: Change the password on first login!"