david_igou.armbian.pxelinux_render role – Render one per-board pxelinux.cfg file to a local directory
Note
This role is part of the david_igou.armbian collection (version 0.0.5-alpha).
It is not included in ansible-core.
To check whether it is installed, run ansible-galaxy collection list.
To install it use: ansible-galaxy collection install david_igou.armbian.
To use it in a playbook, specify: david_igou.armbian.pxelinux_render.
Entry point main – Render one per-board pxelinux.cfg file to a local directory
Synopsis
Renders an 01-<mac> pxelinux.cfg file using the supplied board identity and netboot parameters. Always writes — never uploads. The caller is responsible for moving the rendered file to the TFTP server.
Typically reached via `delegate_to: localhost` inside a `hosts: boards` play, so per-board hostvars are in scope and one invocation per board renders one file.
Requires the caller to have resolved `armbian_board_config` on the running host before invocation (typically via `_resolve_board_config.yml` in the calling playbook’s pre_tasks). The template reads `armbian_board_config.console` and `armbian_board_config.earlycon` directly.
Breaking change (per-host refactor): every external input is now `pxelinux_render_*`-prefixed (previously unprefixed). See the role README for the full rename table.
Parameters
Parameter |
Comments |
|---|---|
Board MAC address; used to compute the 01-<mac> filename. |
|
Which label the rendered pxelinux.cfg’s `default` directive points at. Built-in choices: nfs, sd, local, local_kernel. May also be any key in pxelinux_render_extra_modes. Validated at task level against the union {nfs, sd, local, local_kernel} ∪ keys(pxelinux_render_extra_modes). `local_kernel` selects a localboot-only label whose body is `localboot 0`; the U-Boot environment’s `localcmd` decides what runs (typically a `bootflow scan -b` that hands off to the extlinux bootmeth on a local disk). |
|
User-defined named boot modes. Each entry adds a label to the rendered pxelinux.cfg with the supplied root= and rootfstype. Keys become label names and valid pxelinux_render_boot_mode values. Default: |
|
Inventory hostname — used as both the per-host NFS subdir and the menu-label suffix. |
|
root= kernel argument for the `local` label. Must match the filesystem label disk_provision wrote at mkfs time (default armbi_root_local). Override per-host when the board has multiple local disks carrying that label or when you want to refer to the partition by UUID / PARTUUID / PARTLABEL. Default: |
|
NFS export root path. Per-host directory is composed as <pxelinux_render_nfs_root_path>/<pxelinux_render_hostname>. |
|
Server IP written into nfsroot=. |
|
Local directory where 01-<mac> is written. |
|
When true, appends verbose console/debug kernel arguments (earlycon, loglevel=8, ignore_loglevel, initcall_debug, and systemd console logging) to every label’s append line, for diagnosing boot failures over serial. Default false renders a quiet boot. Choices:
|
|
root= kernel argument for the `sd` label. Defaults to the Armbian SD-card filesystem label armbi_root; override per-host (via armbian_sd_root) when the board’s SD rootfs uses a different label, UUID, or PARTUUID. Default: |
|
TFTP-relative path to the DTB. Defaults to a per-host layout keyed by inventory_hostname. Default: |
|
TFTP-relative path to the initrd. Defaults to a per-host layout keyed by inventory_hostname. Default: |
|
TFTP-relative path to the kernel. Defaults to a per-host layout keyed by inventory_hostname. Default: |