New Out Of Box Software (NOOBS) is a package for the Raspberry Pi system that allows a user to load an operating system on their Pi’s SD card without the use of imaging software. The most common operating system is called Raspbian, which is a fork of Debian. customnoobs
allows the user to create their own customized NOOBS setup with Raspbian. The user chooses their own scripts to be run upon the first boot of Raspbian. This is ideal for installations and configurations that a user would not want to repeat every time they flashed their Raspberry Pi’s SD card. Headless (no monitor or keyboard) installations were in mind when this program was written. It was written to be used in conjunction with the project initPi for automating secure headless setups.
Repeatedly bricking the Raspberry Pi made rapid deployment very desirable, so customizing and streamlining the installation of custom software on the Raspbian operating system was sought as a means to save time. Thus customNOOBS was born in an effort to reduce much wasted time down the line.
customnoobs
files anywhere on your Linux systemcustomnoobs
, passing in your script location(s) as argumentsroot.tar.xz
is a long process)NOOBS
directory onto a freshly formatted SD cardIt is advisable to test your scripts before using this program to compile a custom NOOBS package.
customnoobs
files anywhere on your systemcustomnoobs
as root
and provide the following arguments (in no particular order):
lite
or full
only, default is normal distribution)NOOBS
directory to be created in current working directory (cwd). For this reason, you may wish to run the process in the background.NOOBS
folder (not NOOBS
folder itself) onto the SD cardIn some cases you may need multiple files for your customized installation, whether it’s multiple scripts, or a configuration file, etc. If that is the case, you may provide a directory location along with a file location. All files from the directory will be recursively copied into the customized Raspbian. You must still provide a file location to indicate which script needs to run first. Keep in mind that unless the script you provide references other scripts in the directory, they will not run. The file location must also be an absolute path or a relative path to the cwd. Providing just the filename (i.e.: script.sh
) will not work. The file must also be in the 1st level of the directory provided (i.e.: /../../[dir]/[file]
). If you are concerned about relative references to other files failing, you may use the following absolute path: /usr/local/bin/firstboot/[dir]/
where [dir]
is the name of the parent directory provided.
All files will be copied as root
, so the owner of all directories and files copied will become root
. Permissions will be unaltered, so make sure that the script you provided is executable.
The most recent copy of NOOBS and Raspbian are downloaded and root.tar.xz
is extracted. The user file(s) are copied to /usr/local/bin/firstboot/
(or /usr/local/bin/firstboot/[dir]
, if multiple files). rc.local
is backed up and altered to run a file /usr/local/bin/firstboot
that waits until the first startup is compete, restores rc.local
to it’s original state, and calls the user script. Some minor alterations are made, including setting up a silent (non-interactive) installation of Raspbian. root.tar.xz
is repacked, which take the longest amount of time.
No further contribution is needed as Raspbian has been replaced by Raspberry Pi OS, rendering customNOOBS
obsolete.
Thank you very much to Harry Fairhead and his article “Real Raspberry Pi - Getting Started And Custom NOOBS” for being the chief source of information in writing this project.