feat(arch): install bluetooth utilities

This commit is contained in:
Price Hiller 2023-06-03 22:10:38 -05:00
parent 8f62302af0
commit f6594de7ee
Signed by: Price
SSH Key Fingerprint: SHA256:Y4S9ZzYphRn1W1kbJerJFO6GGsfu9O70VaBSxJO7dF8
2 changed files with 42 additions and 2 deletions

View File

@ -0,0 +1,35 @@
---
# Installs a gui (Blueman), and bluez utils for bluetoothctl
- name: Install Bluetooth tools
become: true
community.general.pacman:
name:
- blueman
- bluez-utils
state: present
- name: Ensure Bluetooth Service is Enabled and Running
ansible.builtin.systemd:
name: bluetooth.service
state: started
enabled: true
- name: Ensure Polkit Perms are in Place for Blueman
become: true
ansible.builtin.copy:
content: |
/* Allow users in wheel group to use blueman feature requiring root without authentication */
polkit.addRule(function(action, subject) {
if ((action.id == "org.blueman.network.setup" ||
action.id == "org.blueman.dhcp.client" ||
action.id == "org.blueman.rfkill.setstate" ||
action.id == "org.blueman.pppd.pppconnect") &&
subject.isInGroup("wheel")) {
return polkit.Result.YES;
}
});
dest: /etc/polkit-1/rules.d/51-blueman.rules
owner: root
group: polkitd
mode: '0644'

View File

@ -155,5 +155,10 @@
state: present
- name: Import Other Arch Tasks
ansible.builtin.import_tasks:
file: reflector.yml
ansible.builtin.include_tasks:
file: '{{ task }}'
loop_control:
loop_var: task
loop:
- reflector.yml
- bluetooth.yml