From ea81317d3757f625c6728ef8b1bd512aa3393332 Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Fri, 24 Mar 2017 13:54:49 +0200 Subject: Implement second stage (systemd) network configuration --- bootstrap | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'bootstrap') diff --git a/bootstrap b/bootstrap index 18343be..c97d30b 100755 --- a/bootstrap +++ b/bootstrap @@ -30,7 +30,7 @@ btrfs=/btrfs release="unstable" mirror="https://deb.debian.org/debian/" passwd="123" #@@ TMP root passwd. -macaddr="DE:AD:BE:EF:B8:DA" # Mac address for testing. +macaddr="de:ad:be:ef:b8:da" # Mac address for testing. root="$btrfs/$id/buildos" @@ -141,9 +141,15 @@ if [ "$stage" -eq "1" ]; then # - systemd-container seems to be required by host systemd-nspawn. # pkgs="locales,systemd-container" - pkgs+=",net-tools,iproute2,iptables,isc-dhcp-client,ifupdown,ntp" - pkgs+=",iputils-ping,wget,curl" + pkgs+=",linux-image-amd64,irqbalance,pciutils" + + pkgs+=",hdparm,btrfs-progs" + + pkgs+=",net-tools,iproute2,iptables,isc-dhcp-client" + pkgs+=",ifupdown,bridge-utils,dnsmasq,ntp" + pkgs+=",iputils-ping,wget,curl" + pkgs+=",less" sudo debootstrap \ @@ -208,6 +214,10 @@ chattr +i /etc/localtime # chpasswd <<<'root:$passwd' +# Enable IPv4 forwarding (used for private bridge NAT). +# +sed -i 's/^# *\(net.ipv4.ip_forward\).*/\1=1/' /etc/sysctl.conf + # Setup locale. We only support en_US.UTF-8. # sed -i 's/^# *\(en_US.UTF-8\)/\1/' /etc/locale.gen -- cgit v1.1