Changes between Version 12 and Version 13 of newport/ubuntu


Ignore:
Timestamp:
08/03/2018 08:32:07 PM (6 years ago)
Author:
Tim Harvey
Comment:

add net-tools and ifupdown and extra env to debootstrap instructions

Legend:

Unmodified
Added
Removed
Modified
  • newport/ubuntu

    v12 v13  
    5858
    59592. Perform first stage install of minimal filesystem for {{{arm64}}} architecture:
    60 {{{
    61 #!bash
    62 target=rootfs
     60{{{#!bash
    6361distro=xenial
    64 sudo debootstrap --arch=arm64 --foreign $distro $target
    65 # copy qemu-arm-static binary for the binfmt packages to find it and copy in resolv.conf from host
    66 sudo cp /usr/bin/qemu-aarch64-static $target/usr/bin
    67 }}}
    68  * See http://ports.ubuntu.com/ubuntu-ports/dists/ for a list of current Ubuntu releases: 16.10=yakkety (latest), 16.04=xenial (latest LTS), 15.04=vivid, 14.10=utopic (LTS), 14.04=trusty (LTS), 12.04=precise (LTS), 10.04=lucid (LTS).
    69  * this minimal rootfs can be considered about the same as an Ubuntu-core downloaded rootfs however it is still missing some core packages and configuration before it can be booted. These steps are taken care of in a 2nd stage install within a chroot shell
     62arch=arm64
     63target=${distro}-${arch}
     64qemu_arch=aarch64
     65sudo debootstrap --arch=$qemu_arch --foreign $distro $target
     66# copy qemu binary for the binfmt packages to find it and copy in resolv.conf from host
     67sudo cp /usr/bin/qemu-${qemu_arch}-static $target/usr/bin
     68}}}
     69 * See http://ports.ubuntu.com/ubuntu-ports/dists/ for a list of current Ubuntu releases: 18.04=bionic (latest LTS), 16.04=xenial
     70 * this minimal rootfs is still missing some core packages and configuration before it can be booted. These steps are taken care of in a 2nd stage install within a chroot shell
    7071 * the chroot shell below will provide network support (inherited from the host)
    7172
     
    7475#!bash
    7576sudo chroot $target
    76 # now we are in the chroot
     77# now we are in the chroot - setup env matching the distro above
    7778distro=xenial
    7879export LANG=C
     
    1241258. (optional) configure networking:
    125126 - wired ethernet with DHCP on eth0
    126 {{{
    127 #!bash
     127{{{#!bash
     128apt-get install net-tools ifupdown
    128129cat <<EOF >> /etc/network/interfaces
    129130allow-hotplug eth0
     
    134135}}}
    135136 - or static IP:
    136 {{{
    137 #!bash
     137{{{#!bash
     138apt-get install net-tools ifupdown
    138139cat <<EOF >> /etc/network/interfaces
    139140allow-hotplug eth0
     
    175176#!bash
    176177exit
    177 sudo rm $target/usr/bin/qemu-arm-static
     178sudo rm $target/usr/bin/qemu-$qemu_arch-static
    178179}}}
    179180