Files
raspi/playbooks/disable_leds.yml
2024-11-06 21:09:38 -05:00

29 lines
838 B
YAML

---
- name: Disable Wi-Fi and Bluetooth on Raspberry Pi
hosts: all
become: yes
tasks:
- name: Ensure Led disabled in config.txt
lineinfile:
path: /boot/firmware/config.txt
regexp: '^#?dtparam=act_led_trigger=none'
line: 'dtparam=act_led_trigger=none'
state: present
create: yes
- name: Ensure Act Led is disabled in config.txt
lineinfile:
path: /boot/firmware/config.txt
regexp: '^#?dtparam=act_led_activelow=off'
line: 'dtparam=act_led_activelow=off'
state: present
create: yes
- name: Ensure Pwr Led is disabled in config.txt
lineinfile:
path: /boot/firmware/config.txt
regexp: '^#?dtparam=pwr_led_activelow=off'
line: 'dtparam=pwr_led_activelow=off'
state: present
create: yes