refactor: packaging RPM uniquement avec builder Rocky Linux 9
Some checks failed
Build RPM Package / Build RPM Packages (CentOS 7, Rocky 8/9/10) (push) Has been cancelled
Some checks failed
Build RPM Package / Build RPM Packages (CentOS 7, Rocky 8/9/10) (push) Has been cancelled
- Suppression complète du support DEB (Debian/Ubuntu) - Builder Rocky Linux 9 pour compatibilité binaire maximale - Compilation dynamique avec libpcap comme dépendance runtime - Activation du dépôt CRB pour libpcap-devel - RPM générés pour el7, el8, el9, el10 - Mise à jour documentation et workflows GitHub Actions Fix: erreur 'libpcap.so.0.8: cannot open shared object file' sur Rocky Linux 9 Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
This commit is contained in:
@ -1,34 +0,0 @@
|
||||
#!/bin/bash
|
||||
# Test DEB package installation in Debian/Ubuntu container
|
||||
set -e
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
PROJECT_ROOT="$(dirname "$(dirname "$SCRIPT_DIR")")"
|
||||
BUILD_DIR="${PROJECT_ROOT}/build/deb"
|
||||
|
||||
echo "=========================================="
|
||||
echo " Testing DEB Package Installation"
|
||||
echo "=========================================="
|
||||
|
||||
# Find the DEB package
|
||||
DEB_PACKAGE=$(ls -1 "${BUILD_DIR}"/*.deb 2>/dev/null | head -1)
|
||||
if [ -z "$DEB_PACKAGE" ]; then
|
||||
echo "Error: No .deb package found in ${BUILD_DIR}"
|
||||
echo "Run 'make package-deb' first"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "Found package: ${DEB_PACKAGE}"
|
||||
|
||||
# Test installation directly in Debian container
|
||||
echo ""
|
||||
echo "Running installation tests in Debian container..."
|
||||
docker run --rm \
|
||||
-v "${BUILD_DIR}:/packages:ro" \
|
||||
debian:latest \
|
||||
sh -c "apt-get update && apt-get install -y /packages/*.deb && echo 'DEB installation successful'"
|
||||
|
||||
echo ""
|
||||
echo "=========================================="
|
||||
echo " DEB Package Test Complete"
|
||||
echo "=========================================="
|
||||
@ -33,11 +33,12 @@ test_rpm_install() {
|
||||
fi
|
||||
|
||||
# Determine package manager and install command
|
||||
# CentOS 7 is EOL, need to configure vault.centos.org
|
||||
# Note: libpcap is required at runtime (dynamically linked)
|
||||
local setup_cmd=""
|
||||
local install_cmd=""
|
||||
case "$image" in
|
||||
centos:7)
|
||||
# CentOS 7 is EOL, need to configure vault.centos.org
|
||||
setup_cmd="sed -i 's/mirror.centos.org/vault.centos.org/g' /etc/yum.repos.d/*.repo && sed -i 's/^#.*baseurl=http/baseurl=http/g' /etc/yum.repos.d/*.repo && sed -i 's/^mirrorlist=http/#mirrorlist=http/g' /etc/yum.repos.d/*.repo"
|
||||
install_cmd="${setup_cmd} && yum install -y libpcap && yum install -y /packages/*.rpm"
|
||||
;;
|
||||
|
||||
Reference in New Issue
Block a user