#!/bin/sh -e start() { /opt/vc/bin/tvservice -o uhubctl -e -l 1-1 -a off uhubctl -e -l 2 -p 3-4 -a off smbftpd -Ds /usr/local/etc/smbftpd.conf modprobe nf_nat_ftp modprobe wireguard ip link add wg0 type wireguard ip addr add 10.7.0.1/24 dev wg0 wg setconf wg0 /usr/local/etc/wireguard/wg0.conf ip link set wg0 up ifconfig wg0 mtu 1440 txqueuelen 1000 iptables -t nat -A POSTROUTING -s 10.7.0.0/24 -o eth0 -j MASQUERADE iptables -t raw -A PREROUTING -p tcp --dport 21 -j CT --helper ftp iptables -t nat -A POSTROUTING -s 10.8.0.0/24 -o eth0 -j MASQUERADE } start >/dev/null 2>&1 & exit 0