@@ -1349,6 +1349,17 @@ install_dahdi() {
1349
1349
sleep 2
1350
1350
fi
1351
1351
1352
+ # Requests to downloads.digium.com usually use IPv4, but sometimes use IPv6
1353
+ # This is problematic on GitHub Action Runners, which have IPv6 disabled,
1354
+ # and won't let you enable it
1355
+ IPV6_DISABLED=0
1356
+ if which sysctl > /dev/null; then
1357
+ # See https://github.com/asterisk/asterisk-ci-actions/blob/main/SetupUbuntuRunner/action.yml
1358
+ printf " IPv6 Disabled: "
1359
+ sysctl net.ipv6.conf.all.disable_ipv6
1360
+ IPV6_DISABLED=$( sysctl net.ipv6.conf.all.disable_ipv6 | cut -d ' =' -f2 | xargs | tr -d ' \n' )
1361
+ fi
1362
+
1352
1363
# Check that the kernel sources are really present
1353
1364
# /usr/src/linux-headers-* on Debian
1354
1365
# /usr/src/kernels on Rocky Linux
@@ -1458,6 +1469,14 @@ install_dahdi() {
1458
1469
mv $AST_SOURCE_PARENT_DIR /$DAHDI_LIN_SRC_DIR /drivers/dahdi/xpp/Kbuild $AST_SOURCE_PARENT_DIR /$DAHDI_LIN_SRC_DIR /drivers/dahdi/xpp/Bad-Kbuild
1459
1470
fi
1460
1471
1472
+ # If IPv6 is disabled, force wget downloads to use the IPv4 address
1473
+ # Could also use --prefer-family, but is IPv6 is disabled, we have to use IPv4 anyways
1474
+ if [ " $IPV6_DISABLED " = " 1" ]; then
1475
+ echoerr " IPv6 is disabled, forcing driver downloads to use only IPv4..."
1476
+ sed -i ' s/WGET_ARGS:=--continue/WGET_ARGS:=--inet4-only --continue/g' drivers/dahdi/firmware/Makefile
1477
+ grep " WGET" drivers/dahdi/firmware/Makefile
1478
+ fi
1479
+
1461
1480
make -j$( nproc) $DAHDI_CFLAGS
1462
1481
if [ $? -ne 0 ]; then
1463
1482
echoerr " DAHDI Linux compilation failed, aborting install"
@@ -2490,7 +2509,7 @@ if which curl > /dev/null; then # only execute if we have curl
2490
2509
# Only download the first few lines of the file, to get the latest version number, and only check every so often
2491
2510
recent=$( find /tmp/phreaknet_upstream_version.txt -mmin -720 2> /dev/null | wc -l )
2492
2511
if [ " $recent " != " 1" ]; then
2493
- printf " *** Checking if a more recent version is available..."
2512
+ printf " *** Checking if a higher numbered version is available..."
2494
2513
curl --silent https://raw.githubusercontent.com/InterLinked1/phreakscript/master/phreaknet.sh -r 0-210 > /tmp/phreaknet_upstream_version.txt
2495
2514
# Compare current version with latest upstream version
2496
2515
upstream=` grep -m1 " # v" /tmp/phreaknet_upstream_version.txt | cut -d' v' -f2`
0 commit comments