+# Generator for Oktopus boot media
+# Copyright (C) 2018 Hochschule für Technik und Wirtschaft Berlin
+# written by Paul Hänsch <oktopus@plutz.net>
+#
+# This program is free software: you can redistribute it and/or modify
+# it under the terms of the GNU Affero General Public License as published by
+# the Free Software Foundation, either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU Affero General Public License for more details.
+#
+# You should have received a copy of the GNU Affero General Public License
+# along with this program. If not, see <https://www.gnu.org/licenses/>.
+
.FORCE:
BOOTSTRAP = http://raspbian.raspberrypi.org/raspbian
deb http://archive.raspberrypi.org/debian stretch main\n
endef
-PACKAGES := apt apt-transport-https bluez bluez-firmware btrfs-tools busybox-static bzip2 ca-certificates cron deborphan firmware-atheros firmware-brcm80211 firmware-libertas firmware-linux-free firmware-misc-nonfree firmware-realtek gzip htop ifupdown init iptables iputils-ping irqbalance isc-dhcp-client less libraspberrypi-bin libraspberrypi0 make net-tools nmap ntpdate openssh-client openssh-server p7zip-full raspberrypi-bootloader raspberrypi-kernel rsync ssh sshfs sudo systemd traceroute unace unrar-free unzip vim wget wireless-tools wpasupplicant xz-utils zip
+PACKAGES := apt apt-transport-https bluez bluez-firmware bluez-tools bridge-utils btrfs-tools busybox-static bzip2 ca-certificates cron deborphan dnsmasq firmware-atheros firmware-brcm80211 firmware-libertas firmware-linux-free firmware-misc-nonfree firmware-realtek gzip htop ifupdown init iptables iputils-ping irqbalance isc-dhcp-client less libraspberrypi-bin libraspberrypi0 make net-tools nmap ntpdate openbsd-inetd openssh-client openssh-server p7zip-full pi-bluetooth rpi-update rsync ssh sshfs sudo systemd traceroute unace unrar-free unzip vim wget wireless-tools wpasupplicant xz-utils zip
# Do not change, only override in config.mk
WIFI-SSID =
chroot "$@" apt-get --yes install ${PACKAGES}
chroot "$@" apt-get --yes --auto-remove purge
chroot "$@" apt-get --yes --auto-remove upgrade
- chroot "$@" rm /usr/local/sbin/invoke-rc.d
+ chroot "$@" rpi-update || [ -f "$@/boot/bootcode.bin" ]
+ sync
chroot "$@" apt-get clean
+ chroot "$@" rm /usr/local/sbin/invoke-rc.d
touch "$@"
id_rsa.pub:
files/etc/network/interfaces.d/wifi: wifi.tmpl
sed 's;#WIFI-SSID#;${WIFI-SSID};; s;#WIFI-PASS#;${WIFI-PASS};;' <'$<' >'$@'
+ chmod 644 '$@'
files/root/.ssh/authorized_keys: id_rsa.pub
mkdir -p files/root/.ssh/