mirror of
https://git.bibube.com/nguyen/raspi.git
synced 2024-11-22 22:42:14 +00:00
Disable Wifi and BT
This commit is contained in:
21
playbooks/disable_wifi_bt.yml
Normal file
21
playbooks/disable_wifi_bt.yml
Normal file
@@ -0,0 +1,21 @@
|
||||
---
|
||||
- name: Disable Wi-Fi and Bluetooth on Raspberry Pi
|
||||
hosts: all
|
||||
become: yes
|
||||
tasks:
|
||||
- name: Ensure Wi-Fi is disabled in config.txt
|
||||
lineinfile:
|
||||
path: /boot/firmware/config.txt
|
||||
regexp: '^#?dtoverlay=-disable-wifi'
|
||||
line: 'dtoverlay=-disable-wifi'
|
||||
state: present
|
||||
create: yes
|
||||
|
||||
- name: Ensure Bluetooth is disabled in config.txt
|
||||
lineinfile:
|
||||
path: /boot/firmware/config.txt
|
||||
regexp: '^#?dtoverlay=-disable-bt'
|
||||
line: 'dtoverlay=-disable-bt'
|
||||
state: present
|
||||
create: yes
|
||||
|
||||
@@ -5,7 +5,7 @@ home-k8s1 ansible_host=192.168.0.201 ansible_user=pi ansible_ssh_private_key_fil
|
||||
home-k8s2 ansible_host=192.168.0.202 ansible_user=pi ansible_ssh_private_key_file=~/.ssh/id_rsa
|
||||
home-k8s3 ansible_host=192.168.0.203 ansible_user=pi ansible_ssh_private_key_file=~/.ssh/id_rsa
|
||||
home-k8s4 ansible_host=192.168.0.204 ansible_user=pi ansible_ssh_private_key_file=~/.ssh/id_rsa
|
||||
home-k8s0 ansible_host=192.168.0.205 ansible_user=pi ansible_ssh_private_key_file=~/.ssh/id_rsa
|
||||
#home-k8s0 ansible_host=192.168.0.205 ansible_user=pi ansible_ssh_private_key_file=~/.ssh/id_rsa
|
||||
|
||||
[all:vars]
|
||||
ansible_python_interpreter=/usr/bin/python3
|
||||
|
||||
Reference in New Issue
Block a user