GithubHelp home page GithubHelp logo

xianliy / molohub Goto Github PK

View Code? Open in Web Editor NEW

This project forked from 274947104/molohub

0.0 1.0 0.0 1.82 MB

Home Assistant 远程访问小白方案,应用商店HACS方式安装molohub远程控制你的家~!

Home Page: http://1t.click/avAU

Python 100.00%

molohub's Introduction

【中文简介】

img

这是一个将本地的HA控制网页反向代理到公网, 这样公网就可以轻松访问到HA控制台页面, 并控制家里已经连上HA的硬件. 基于安全方面的考虑, 该组件需要经过Google, GitHub或微信小程序的授权才能正常使用.

由于Home Assistant运行于局域网下, 想要通过外网远程访问HA, 首先HA部署环境所在网络下的路由器支持端口映射(port mapping), 映射后在公网通过ip:port直接访问,同时为了方便访问还需要一个ddns服务来把wan ip和动态域名绑定。但是由于网络供应商的网络环境复杂性, 以及用户自身内网环境复杂性, 很难系统性地总结一套通用有效的方法来实现. 上述技术实施起来比较繁琐, 对普通用户来说门槛较高, 本组件旨在简化用户进行远程访问本地HA控制网络.

【一键安装】

在终端直接执行下面命令一键安装molohub:

curl --silent --show-error --retry 5 https://raw.githubusercontent.com/haoctopus/molohub/master/auto_install.py | sudo python

等待提示安装成功后手动重启Home Assistant即可。

若此方法安装失败,请用下面的方法手动安装。有curl组件的Windows用户也可以通过cmd执行一键安装(需要去掉命令中的sudo)。

【安装软件】

下载molohub文件夹,保存在<homeassistant配置目录>/custom_components/目录中,若custom_components目录不存在则自行创建。

  • homeassistant配置目录在哪?

Windows用户: %APPDATA%\.homeassistant

Linux-based用户: 可以通过执行locate .homeassistant/configuration.yaml命令,查找到的.homeassistant文件夹就是配置目录。

群晖Docker用户: 进入Docker - 映像 - homeassistant - 高级设置 - 卷, /config对应的路径就是配置目录

img

【HA中配置实例】

molohub:
  dismissable: true  # 默认状态下忽略按钮不可用,添加此行来激活忽略按钮.

【多开教程】

如果你需要绑定多个molohub, 与家人一起控制HA, 可以通过以下步骤实现molohub多开:

  1. 进入到homeassistant配置目录的custom_components文件夹
  2. 复制粘贴molohub文件取名为molohub0
  3. 修改homeassistant配置目录下的configuration.yaml, 添加如下一行代码
molohub0:
  1. 手动重启Home Assistant, 完成. 同理可以添加任意多个molohub.

【相关链接】

平台入口网站:https://www.molo.cn

molohub组件:https://github.com/haoctopus/molohub

【效果展现】

img


img


img


img

【联系我们】

如果安装和使用过程中遇到任何问题,可以通过以下方式联系我们,我们将在看到反馈后第一时间作出回应:

Email: [email protected]

QQ群: 598514359



【Description in English】

img

This is a component forwards the local HA control web page to the public network, so that the public network can be easily accessed, and interact with the hardwares at home that has connected to the HA. For security reasons, this component needs to be authorized by Google, GitHub or Wechat Mini Program to work properly.

when Home Assistant runs under the LAN, if you want to access the HA remotely through the WAN, the router under the network where the HA deployed must supports port mapping , and will be directly accessible on the public network after mapping. also generally ddns is also needed to solve ip change problem. But due to the network provider's The complexity of the network environment, and the complexity of the user's own internet environment, it is difficult to systematically summarize a set of general and effective methods to achieve the target. The above technology is more complicated to implement, and the threshold for ordinary users is higher. This project aims to simplify users to remotely access the local HA control network.

【One-key install】

If you are Linux-based user, run the command below to install molohub automatically:

curl --silent --show-error --retry 5 https://raw.githubusercontent.com/haoctopus/molohub/master/auto_install.py | sudo python

Wait untill installation success, and restart your Home Assistant.

If this not working, please install molohub manually according to the next section. For Windows user with curl component, remove sudo in command and run it in cmd.

【Installation】

Download molohub folder and put it under homeassistant configuration directory/custom_components/. If custom_components doesn't exist, create one.

  • Where is homeassistant configuration directory?

Windows user: %APPDATA%\.homeassistant

Linux-based user: Run command line locate .homeassistant/configuration.yaml. The .homeassistant folder in the returning result is the configuration directory.

Synology NAS Docker user: Go to Docker - Images - Homeassistant - Advanced settings - Volumes, the path corresponding to /config is the configuration directory.

img

【Configuration】

molohub:
  dismissable: true  # Dismiss button is disable by default, add this line to enable.

【Mulit-client】

If you need to bind multiple molohubs to control HA with your family, you can open more molohub by following the steps below:

  1. goto homeassistant configuration directory's custom_components folder
  2. copy paste molohub folder named molohub0
  3. modify homeassistant configuration file configuration.yaml, add a line as below:
molohub0:
  1. manully restart Home Assistant, done. You can add as more as you want by using this method

【Reference link】

Platform entrance link:https://www.molo.cn

molohub component:https://github.com/haoctopus/molohub

【Demonstration】

img


img


img


img

【Contact us】

Please contact us if you have any questions about installation and using molohub. We will respond as soon as we see the feedback.

Email: [email protected]

QQGroup: 598514359

molohub's People

Contributors

haoctopus avatar 5high avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.