Files
ansible/roles/pi_standard_setup
Martin Bauer 07e3c2797e Fix pi_standard_setup under --check
Skipped command tasks return stdout: "" rather than being undefined, so
"src: motd/{{ ...stdout }}" collapsed to "motd/" - a directory - and copy
switched to recursive mode, failing with "/etc/motd/<file>: Not a
directory". The empty boot-target stdout likewise never equals
"multi-user.target", so "Set boot mode to CLI" always reported changed.

Run the three read-only commands in check mode. They are all
changed_when: false already, so this is safe.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-19 16:22:50 +02:00
..
2026-09-19 16:22:50 +02:00

pi_standard_setup

Baseline provisioning applied to every Pi: apt update/upgrade, detects the Pi model, adds a root SSH key, disables the SSH locale-forwarding warning, optionally configures wifi and the hostname, and rotates the default pi/raspberry credentials via the keepass lookup plugin.

Key vars: pi_standard_setup_wifi_ssid, pi_standard_setup_new_hostname, pi_standard_setup_timezone, pi_standard_setup_wifi_country, ansible_ssh_pass (the OS-default password, used only to reach a freshly-flashed Pi for the first time before its password is rotated)