Add matter and openthread support
This commit is contained in:
@@ -6,6 +6,12 @@
|
||||
- name: Pull Home Assistant image
|
||||
containers.podman.podman_image:
|
||||
name: ghcr.io/home-assistant/home-assistant:stable
|
||||
- name: Pull Matter Server image
|
||||
containers.podman.podman_image:
|
||||
name: ghcr.io/matter-js/python-matter-server:stable
|
||||
- name: Pull openthread image
|
||||
containers.podman.podman_image:
|
||||
name: openthread/border-router:latest
|
||||
- name: Create network for iot interface
|
||||
containers.podman.podman_network:
|
||||
name: iot
|
||||
@@ -14,17 +20,21 @@
|
||||
containers.podman.podman_network:
|
||||
name: infra
|
||||
macvlan: ens18
|
||||
- name: Create config directory
|
||||
- name: Create config directories
|
||||
ansible.builtin.file:
|
||||
path: /var/homeassistant
|
||||
path: { { item } }
|
||||
state: directory
|
||||
loop:
|
||||
- /var/homeassistant
|
||||
- /var/matter_server
|
||||
- /var/thread_router
|
||||
- name: Create Home Assistant Container
|
||||
containers.podman.podman_container:
|
||||
name: homeassistant
|
||||
image: ghcr.io/home-assistant/home-assistant:stable
|
||||
recreate: true
|
||||
restart: true
|
||||
restart_policy: "unless-stopped"
|
||||
hostname: homeassistant1
|
||||
network:
|
||||
- iot
|
||||
- infra
|
||||
@@ -32,3 +42,40 @@
|
||||
state: started
|
||||
volumes:
|
||||
- "/var/homeassistant:/config"
|
||||
- name: Create Matter Server Container
|
||||
containers.podman.podman_container:
|
||||
name: matter
|
||||
image: ghcr.io/matter-js/python-matter-server:stable
|
||||
hostname: matter1
|
||||
recreate: true
|
||||
restart_policy: "unless-stopped"
|
||||
network:
|
||||
- iot
|
||||
- infra
|
||||
privileged: true
|
||||
state: started
|
||||
volumes:
|
||||
- "/var/matter_server:/data"
|
||||
- name: Create OpenThread container
|
||||
containers.podman.podman_container:
|
||||
name: thread
|
||||
image: ghcr.io/matter-js/python-matter-server:stable
|
||||
hostname: openthread1
|
||||
recreate: true
|
||||
restart_policy: "unless-stopped"
|
||||
network:
|
||||
- iot
|
||||
device: "/dev/serial/by-id/usb-Nabu_Casa_ZBT-2_10B41DE60794-if00:/dev/ttyACM5"
|
||||
privileged: true
|
||||
state: started
|
||||
volumes:
|
||||
- "/var/thread_router:/data"
|
||||
env:
|
||||
OT_RCP_DEVICE: "spinel+hdlc+uart:///dev/ttyACM5?uart-baudrate=460800"
|
||||
OT_INFRA_IF: "eno1"
|
||||
OT_THREAD_IF: "wpan0"
|
||||
OT_LOG_LEVEL: "1"
|
||||
OT_REST_LISTEN_ADDR: "0.0.0.0"
|
||||
OT_REST_LISTEN_PORT: "8981"
|
||||
OT_WEB_LISTEN_ADDR: "0.0.0.0"
|
||||
OT_WEB_LISTEN_PORT: "8980"
|
||||
|
||||
Reference in New Issue
Block a user