Build (and cross-compile) your own image for Raspberry Pi
Switch branches/tags
Nothing to show
Clone or download
Latest commit ac7c8c2 Nov 8, 2016


Build (and cross-compile) your own image for Raspberry Pi

Set of bash scripts for your Debian or Ubuntu Linux to create your own .img file for Raspberry Pi. Have your own image with YOUR content in minutes!

Initial script was taken from the [Klaus Maria Pfeiffer blog] (

About initial code

Original script was created to burn Debian Wheezy, my target is Raspbian, which is better for Raspberry Pi. You can read more about Raspbian (and its difference from stock Debian) at project page:

Milestones of this project

  • Add script to create minimal Raspbian image
  • Add image mount / unmount script with cross-compilation environment for mounted system
  • Be able to deploy images (add individual hostname and root password, OpenVPN client settings)


It is possible to prepare environment on almost every Linux, where chroot, QEMU and debootstrap exists. I strictly recommend to install apt-cacher-ng (apt-get install apt-cacher-ng), that caches all downloaded deb packages and lets you to use deb_local_mirror, what's extreamely useful for further experiments, system won't download packages from internet anymore! [Read more about apt-cacher-ng] (

Install minimal set of packages: ./

Run script, do burn your SD card

./ /dev/sdX

OR to create IMG file (you'll find it under /tmp/rpi folder)