Git Product home page Git Product logo

ha-frps-0.19.1's Introduction

Hass.io frp client

A fast reverse proxy client for Hass.io to help you expose a home assistant or any other local service behind a NAT or firewall to the internet.

Read more about the project: https://github.com/fatedier/frp

How to use?

  1. Add a frpc.int configuration file to /share/frp directory
  2. Run frps on remote server with public ip
  3. Start Hass.io addon

Example for home assistant

I don't use frp server directly to expose home assistant to the net, but have a nginx before it so a have next config

nginx config

upstream frps {
    server 0.0.0.0:8080;
}

server {
    listen 443 ssl;
    server_name <SERVER_NAME>;

    location / {
        proxy_pass http://frps;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection 'upgrade';
        proxy_set_header Host frps123home.hidden; #$host;
        proxy_cache_bypass $http_upgrade;
        proxy_http_version 1.1;
    }

}

frp server config (frps.ini)

[common]
bind_addr = 0.0.0.0
bind_port = 7000

# port should be the same as an upsteam in nginx config
vhost_http_port = 8080
vhost_https_port = 8081

# dashboard used by a client
dashboard_addr = 0.0.0.0
dashboard_port = 7500

# makes sense to protect admin panel with a password since it is exposed to the net
dashboard_user = admin
dashboard_pwd = admin

# for authentication
token = sometoken

frp client config for hass.io addon in /share/frp/frpc.ini

# [common] is integral section
[common]
server_addr = <server's ip address>
server_port = 7000

# console or real logFile path like ./frpc.log
log_file = /share/frp/frpc.log

# for authentication
token = sometoken

# set admin address for control frpc's action by http api such as reload
admin_addr = 0.0.0.0
admin_port = 7500
admin_user = admin
admin_pwd = admin

heartbeat_interval = 30
heartbeat_timeout = 90

[homeassistant]
type = http
# home assistant port, usually 812
local_port = 8123
# custom domain, used locally, should much the domain from nginx config
custom_domains = frps123home.hidden

ha-frps-0.19.1's People

Contributors

wocaca avatar

Watchers

 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.