Skip to content

Commit 673a27c

Browse files
committed
boot_folder: explain how to use firstboot
1 parent cfed0fc commit 673a27c

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

configuration/boot_folder.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,14 @@ When this file is present, SSH will be enabled on boot. The contents don't matte
4343

4444
This is the file to configure wireless network settings (if the hardware is capable of it). Edit the country code and the network part to fit your case. More information on how to use this file can be found in [the `wireless/headless` section](./wireless/headless.md).
4545

46+
### firstboot
47+
48+
If a `/boot/firstboot` executable exists at boot time, Raspberry Pi OS executes it on the first boot. It may contain bash, python, or any executable arm binary. After execution, `firstboot` will be renamed to firstboot.XXX. Later reboots will know `firsttime.XXX` was already executed.
49+
50+
Use it to provision your Raspberry Pi using a simple scripts or initializing configuration management like cloud-init, puppet or ansible.
51+
52+
Once the system has booted, view status and script output with `systemctl status firstboot` and `journalctl -u firstboot`.
53+
4654
### Device Tree files
4755

4856
There are various Device Tree blob files, which have the extension `.dtb`. These contain the hardware definitions of the various models of Raspberry Pi, and are used on boot to set up the kernel according to which Pi model is detected. More [details here](device-tree.md#part3.1).

0 commit comments

Comments
 (0)