#!/bin/sh # Nico Schottelius, 2024-07-22 # This script assumes a clean/newly setup openwrt device # # Assumption: # VIIRB being used to... # - monitor camera # - monitor UPS via USB if [ $# -lt 8 ] ; then echo $0 "address hostname passwd wifi-ssid wifi-psk" fi address=$1; shift hostname=$1; shift root_password=$1; shift wifi_ssid=$1; shift wifi_psk=$1; shift # Allow passwordless to avoid nightmare cat ~/.ssh/id_rsa.pub | ssh root@${address} "cat > /etc/dropbear/authorized_keys" cat <