From a242439c4745265d62c7f5b4e14aa754f36e2f55 Mon Sep 17 00:00:00 2001 From: Zakary Timson Date: Sun, 27 Oct 2024 11:30:34 -0400 Subject: [PATCH] Add README.md --- README.md | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 README.md diff --git a/README.md b/README.md new file mode 100644 index 0000000..90b3aa2 --- /dev/null +++ b/README.md @@ -0,0 +1,27 @@ +# Apollo + +## Setup +```sh +sudo apt update && sudo apt upgrade -y +sudo apt install htop i2c-tools +raspi-config # enable i2c +``` + +### MAC fix +```sh +MAC_PREFIX="80:86:00" + +files=( + "/etc/systemd/network/eth0.network" + "/etc/systemd/network/wlan0.network" +) + +for file in "${files[@]}"; do + if [ -n "$(cat $file | grep MACAddress )" ]; then continue; fi + mac_address=$(printf '%02X:%02X:%02X' $((RANDOM % 256)) $((RANDOM % 256)) $((RANDOM % 256))) + cat <> "$file" +[Link] +MACAddress=$MAC_PREFIX:$mac_address +EOF +done +```