Installing Linux from tar archives is cumbersome. An automated way to avoid doing so.
870
=[PLATFORM]= - sets image destitantion platform (default: rpi-3) =[DISTRO_TAR_URL]= - (NOT NEEDED WHEN USING ARCHlINUXARM) a fully qualified URL to your distro's tar.gz (ie. http://archlinuxarm.org/os/ArchLinuxARM-odroid-c2-latest.tar.gz) =(copy|tar)= - whether an img or tar.gz copy shall be created; mandatory when using =PLATFORM= parameter
Or without cloning: #+BEGIN_SRC docker run --privileged -e PLATFORM=${PLATFORM} -v $(pwd):/backup -it peelsky/arm-sdcard-builder -e download copy #+END_SRC
**** Raspberry Pi 3 RPi-3 is the default platform of choice, thus you can simply run: #+BEGIN_SRC docker run --privileged -v $(pwd):/backup -it peelsky/arm-sdcard-builder -e download copy #+END_SRC
**** Problem solving If docker says something's wrong with /dev/loopX, most likely it's due to device mounting, execute: #+BEGIN_SRC docker-machine ssh default -- "losetup -a | cut -c1-10 | xargs -i losetup -d {}" || true docker-machine ssh default -- "losetup -f" || true #+END_SRC
*** Linux #+BEGIN_SRC make [PLATFORM=(...)][DISTRO_TAR_URL=http://.../Archive.tar.gz] linux (tar) #+END_SRC
**** Examples:
To get an .img for flashing on an SD card execute:
=make PLATFORM=rp3 linux=
To get an .tgz archive as a backup:
=make PLATFORM=oc2 TARGET=$(pwd) linux tar=
** Flashing
#+BEGIN_SRC
diskutil unmountDisk /dev/diskX
sudo dd bs=1m if=sdcard.img of=/dev/rdiskX
#+END_SRC
Content type
Image
Digest
Size
144.7 MB
Last updated
over 10 years ago
docker pull peelsky/arm-sdcard-builder