功能列表
- 基于Web的编辑器来修改你的文件
- 上传和下载文件
- 集成Github
- 具有触发器,事件,实体,条件和服务的列表。所选元素在最后一个光标位置插入到编辑器中。
- 检查有效的配置,并且直接点击按钮重新启动Home Assistant
- SSL支持
- 可以提供额外身份验证和IP过滤功能
- 直接链接到家庭助理文档和图标
- 执行shell命令
- 跨平台、能运行Homeassistant的都可以运行
详细内容见https://home-assistant.io/docs/ecosystem/hass-configurator/
为了便于分类管理,我建议在/home/homeassistant/.homeassistant/目录下新建一个目录configurator用于存放以下文件,我的HASS是单用户所以没有设置密码,有密码的要在settings.conf文件里面修改一下。
1.、下载configurator.py settings.conf 两个文件放到/home/homeassistant/.homeassistant/configurator 文件夹内(不同系统位置可能有出入,根据自己实际修改文件夹,我的ubuntu就是/root/.homeassistant/configurator)。
2、 修改settings.conf
{"LISTENIP": "0.0.0.0","LISTENPORT": 8124,"BASEPATH": null,"SSL_CERTIFICATE": null,"SSL_KEY": null,"HASS_API": "http://192.168.1.133:8123/api/","HASS_API_PASSWORD": "PASSWORD","CREDENTIALS": null,"ALLOWED_NETWORKS": [],"BANNED_IPS": [],"BANLIMIT": 0}
3、给configurator.py增加执行权限
cd /home/homeassistant/.homeassistant/configuratorsudo chmod 755 configurator.py
4、运行sudo /home/homeassistant/.homeassistant/configurator/configurator.py /home/homeassistant/.homeassistant/configurator/settings.conf
也可以自己写一个shell执行,比如run.sh
#!/bin/sh/usr/bin/python3 /home/homeassistant/.homeassistant/configurator/configurator.py /home/homeassistant/.homeassistant/configurator/settings.conf &
5、如何让它在HASS中做入口,简单说来就是你可以直接在HASS里面访问到这个编辑器
编辑/home/homeassistant/.homeassistant/configuration.yaml文件,加入以下代码即可。
panel_iframe:configurator:title: 'Configurator'url: 'http://192.168.1.133:8124/'icon: mdi:wrench
文档更新时间: 2017-10-16 17:12 作者:Tristan