From cede3f14a47999fc54fb6bcec1749e6da82bc4b0 Mon Sep 17 00:00:00 2001 From: Andrew Cady Date: Sun, 31 May 2020 20:30:03 -0400 Subject: move file into rootfs/ --- Makefile | 4 ++-- patchroot.sh | 23 ----------------------- rootfs/patchroot.sh | 23 +++++++++++++++++++++++ rootfs/samiztest.yaml | 2 +- 4 files changed, 26 insertions(+), 26 deletions(-) delete mode 100755 patchroot.sh create mode 100755 rootfs/patchroot.sh diff --git a/Makefile b/Makefile index cf700ee..65733be 100644 --- a/Makefile +++ b/Makefile @@ -222,7 +222,7 @@ apt-get-update-stamp: FORCE @if $(stale); then set -x; sudo apt-get update && touch $@; fi rootfs/samizdat.patch.btrfs: rootfs/samizdat.seed.btrfs \ - $(if $(INTERACTIVE_CHROOT),FORCE,patchroot.sh) + $(if $(INTERACTIVE_CHROOT),FORCE,rootfs/patchroot.sh) ifneq ($(shell id -u),0) $(SUDO_MAKE) $@ else @@ -241,7 +241,7 @@ else ifdef INTERACTIVE_CHROOT chroot $@.mnt bash -i else - chroot $@.mnt sh < patchroot.sh + chroot $@.mnt sh < rootfs/patchroot.sh endif umount $@.mnt losetup -f $< diff --git a/patchroot.sh b/patchroot.sh deleted file mode 100755 index 76eb26a..0000000 --- a/patchroot.sh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh -hostname=adam -echo $hostname > /etc/hostname -sed -i -e 's/\blocalhost\b/& '"$hostname"'/' /etc/hosts - -. /etc/os-release - -# TODO: Write this in fsmgr -cat < /etc/apt/sources.list -deb http://httpredir.debian.org/debian ${VERSION_CODENAME} main #contrib non-free -deb http://security.debian.org ${VERSION_CODENAME}/updates main #contrib non-free -#deb http://httpredir.debian.org/debian ${VERSION_CODENAME}-backports main #contrib non-free -END - -set -- /var/lib/apt/lists/*_Packages -if [ -f "$1" ] -then - # apt database validity demonstration - apt-get update - apt-cache dumpavail | dpkg --update-avail - - apt-get -yd install iso-codes # baresip - apt-mark install baresip -fi diff --git a/rootfs/patchroot.sh b/rootfs/patchroot.sh new file mode 100755 index 0000000..76eb26a --- /dev/null +++ b/rootfs/patchroot.sh @@ -0,0 +1,23 @@ +#!/bin/sh +hostname=adam +echo $hostname > /etc/hostname +sed -i -e 's/\blocalhost\b/& '"$hostname"'/' /etc/hosts + +. /etc/os-release + +# TODO: Write this in fsmgr +cat < /etc/apt/sources.list +deb http://httpredir.debian.org/debian ${VERSION_CODENAME} main #contrib non-free +deb http://security.debian.org ${VERSION_CODENAME}/updates main #contrib non-free +#deb http://httpredir.debian.org/debian ${VERSION_CODENAME}-backports main #contrib non-free +END + +set -- /var/lib/apt/lists/*_Packages +if [ -f "$1" ] +then + # apt database validity demonstration + apt-get update + apt-cache dumpavail | dpkg --update-avail - + apt-get -yd install iso-codes # baresip + apt-mark install baresip +fi diff --git a/rootfs/samiztest.yaml b/rootfs/samiztest.yaml index 4fcaa9f..42ca627 100644 --- a/rootfs/samiztest.yaml +++ b/rootfs/samiztest.yaml @@ -1,6 +1,6 @@ parent: samizdat binaries: -- '../patchroot.sh' +- './patchroot.sh' seedme: 600000000 apt-update: true -- cgit v1.2.3