anyfesto
anyfesto copied to clipboard
Why Is The IP Not Variable
Dear lord Tom, in this day and age....hard coding the IP? For the love of all that is good, fix plez.
Have the user set it in the config, and each script, notable the m3u playlists and the VLC launcher, read it live.
From Bish-Bash-Bosh
ip="$(ip addr | grep 'state UP' -A2 | tail -n1 | awk '{print $2}' | cut -f1 -d'/')"
In the PI section these files need to be changed..
- AnyfestoPI-index.html
- dhcpdpi.conf
- dnsmasqpi.conf
- interfacespi
- ircd.motd
- ircdpi.conf
- kiwiconfig.js
- startpi.sh
- stream.m3u
While we are at it the hostname/ssid
- hostnamepi
- hostspi
- ircdpi.conf
Add to install script in the configs section For Anyfesto
ip=IpYouWantAnyfestoInstallToHave grep -RiIl '10.11.99.1' | xargs sed -i 's/search/$ip/g'
or for Localfesto
ip="$(ip addr | grep 'state UP' -A2 | tail -n1 | awk '{print $2}' | cut -f1 -d'/')" grep -RiIl '10.11.99.1' | xargs sed -i 's/10.11.99.1/$ip/g'