To use the playbooks you need to have a current version of ansible. Additionally, you should run ansible-galaxy install -r requirements.yml
in your cloned repository folder once to download the dependencies.
The room-assistant.yml
playbook allows you to install and manage a cluster of room-assistant installations. For this you need to create an inventory file with the hosts you want to manage and their configuration. Below is an example for such a hosts.yml
file.
all:
hosts:
'living-room.local':
ansible_user: pi
ansible_password: raspberry
room_assistant_config:
global:
integrations:
- homeAssistant
- bluetoothClassic
- omronD6t
- gpio
gpio:
binarySensors:
- name: Motion Sensor
pin: 17
deviceClass: motion
'bedroom.local':
ansible_user: pi
ansible_password: raspberry
vars:
room_assistant_global_config:
global:
integrations:
- homeAssistant
- bluetoothClassic
homeAssistant:
mqttUrl: mqtt://hassio.local:1883
mqttOptions:
username: room-assistant
password: secretpass
bluetoothClassic:
addresses:
- 'xx:xx:xx:xx:xx:xx'
Note that instead of using user/password you can also use public key authentication if you previously setup your Pis to allow this.
Variable | Default | Description |
---|---|---|
room_assistant_version |
latest |
The version of room-assistant to install, as denoted on npm. |
room_assistant_peer_dependencies |
[] |
List of npm dependency names that you may want to install in addition to room-assistant. |
room_assistant_global_config |
A room-assistant config that should be used across all instances. | |
room_assistant_config |
A room-assistant config for specific hosts. Options that are also in the global config will be overridden. |