defaults = { 'apt': { 'clean_old_kernels': False, 'packages': { 'dhcpcd5': { 'installed': False, }, 'dphys-swapfile': { 'installed': False, }, 'isc-dhcp-client': { 'installed': False, }, 'isc-dhcp-common': { 'installed': False, }, }, 'repos': { 'raspi': { 'install_gpg_key': False, 'items': { 'deb http://archive.raspberrypi.org/debian/ {os_release} main', }, }, }, }, 'raspberrypi': { 'cmdline': { 'console=tty1', 'root=/dev/mmcblk0p2', 'rootfstype=ext4', 'elevator=deadline', 'fsck.repair=yes', 'rootwait', 'quiet', 'plymouth.ignore-serial-consoles', 'net.ifnames=0', }, 'default-target': 'multi-user.target', 'enable_display': False, }, 'systemd': { 'journal': { 'storage': 'volatile', 'maxuse': '100M', 'keepfree': '100M', }, }, } @metadata_reactor.provides( 'raspberrypi/cmdline', ) def display(metadata): if not metadata.get('raspberrypi/enable_display'): return {} return { 'raspberrypi': { 'cmdline': { 'video=DSI-1:800x480@60,rotate=180', }, }, }