2020-11-04 13:36:05 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
if [ $# -lt 1 ]; then
|
|
|
|
echo "$0 ip-address"
|
|
|
|
echo " ip-address: where to find the device"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
openwrt_ip=$1; shift
|
|
|
|
|
|
|
|
ping -c3 ${openwrt_ip}
|
|
|
|
if [ $? -ne 0 ]; then
|
|
|
|
echo "Cannot reach ${openwrt_ip}, aborting"
|
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
cat <<EOF | ssh -t "root@${openwrt_ip}"
|
|
|
|
opkg update
|
2020-11-04 13:39:32 +00:00
|
|
|
opkg install kmod-iwlwifi iwlwifi-firmware-iwl7265d wpa-supplicant
|
2020-11-04 13:36:05 +00:00
|
|
|
EOF
|