npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

rocket-smart-home-ui

v1.0.0

Published

Configuration UI plugin for Rocket Smart Box

Downloads

2

Readme

npm npm Donate

Supported Languages: :gb: :de: :fr: :poland: :czech_republic: :ru: :cn: :hungary: :jp: :es:

Rocket Smart Home UI

This is a plugin for Homebridge. This is a fork of the work originally done by mkellsy.

This plugin allows you to monitor, backup and configure your Homebridge server from a browser.

Status

Installation Instructions

sudo npm install -g --unsafe-perm homebridge-config-ui-hoobs

Once you have installed and configured the plugin you can access the interface via http://localhost:8080.

The default username is admin and the default password is admin.

Configuration

Add this to your homebridge config.json file

"platforms": [
    {
      "platform": "config",
      "name": "Config",
      "port": 8080,
      "sudo": false
    }
]

Optional Settings

  • log - See below for details.
  • sudo - See below for details.
  • restart - The command to run when a restart request is sent from the browser. If not populated it will just terminate the Homebridge process and let your process manager (like systemd) restart it.
  • temp - The path to the file that can display your current CPU temperature in WEB UI. eg. /sys/class/thermal/thermal_zone0/temp
  • theme - The colour scheme to use. Possible values: red, pink, purple, indigo, blue, blue-grey, green, orange. Defaults to red.
  • ssl - See below for details

Accessory Control

The plugin allows you to view and control some types of Homebridge accessories from your web browser.

To enable accessory control you must be running Homebridge in insecure mode:

homebridge -I

Insecure mode, as it's name suggests, is not secure. Anyone with network access to your Homebridge server port and pin will be able to control your accessories. Unless exposing the Homebridge port to the internet, this will generally not be a problem as access will be limited to people already on your local network. Remote access via a home hub (Apple TV, iPad, HomePod etc.) will still be secure. Enable at your own risk.

Not all accessory types are supported. See this issue for a full list of supported accessory types.

Log Viewer Configuration

Homebridge Config UI X allows you to view the homebridge process logs in the browser. These logs can be loaded from a file or from a command.

Logs From File

Example loading logs from a file, change /var/log/homebridge.log to the actual location of your log file:

"platforms": [
    {
      "platform": "config",
      "name": "Config",
      "port": 8080,
      "log": {
        "method": "file",
        "path": "/var/log/homebridge.log"
      }
    }
]

Make sure the user which is running the Homebridge process has the correct permissions to read the log file. You may need to enable the sudo option to avoid permission errors if you are not running Homebridge as root.

Logs From Systemd

If you're using systemd to manage the Homebridge process then you can just set the method to systemd:

"platforms": [
    {
      "platform": "config",
      "name": "Config",
      "port": 8080,
      "restart": "sudo -n systemctl restart homebridge",
      "log": {
        "method": "systemd",
        "service": "homebridge"
      }
    }
]

You may need to enable the sudo option to avoid permission errors if you are not running Homebridge as root.

Logs From Custom Command

The log option can alternatively specify a command to spawn that will stream the logs to the client. This command should stream the logs to stdout:

"platforms": [
    {
      "platform": "config",
      "name": "Config",
      "port": 8080,
      "log": {
        "method": "custom",
        "command": "sudo -n tail -n 100 -f /var/log/homebridge.log"
      }
    }
]

Sudo Mode

Many operations performed by Homebridge Config UI X, such as installing plugins, upgrading Homebridge and viewing the logs can require root permissions. You can run the Homebridge service as root or you can enable the sudo option in the config.

"platforms": [
    {
      "platform": "config",
      "name": "Config",
      "port": 8080,
      "sudo": true
    }
]

When sudo mode is enabled Homebridge Config UI X will use sudo when executing installing, removing or upgrading plugins, viewing the logs using the Logs From File or Logs From Systemd method, and when upgrading Homebridge. It will not be used for Logs From Custom Command or custom restart commands.

Password-less sudo required

For sudo mode to work password-less sudo is required. You can enable password-less sudo by adding this entry to the bottom of your /etc/sudoers file (use visudo to edit the file!):

homebridge    ALL=(ALL) NOPASSWD: ALL

Replace homebridge with the actual user you are running Homebridge as.

Enabling SSL

You can run this plugin over an encrypted HTTPS connection by configuring the ssl options.

"platforms": [
    {
      "platform": "config",
      "name": "Config",
      "port": 8080,
      "ssl": {
        "key": "/path/to/privkey.pem",
        "cert": "/path/to/fullchain.pem"
      }
    }
]

Or if using a PKCS#12 certificate you can setup SSL like this:

"platforms": [
    {
      "platform": "config",
      "name": "Config",
      "port": 8080,
      "ssl": {
        "pfx": "/path/to/cert.pfx",
        "passphrase": "sample"
      }
    }
]

Usage

Status Screen

This shows you that the services are running. It also has your HomeKit pin.

Status

Log Screen

This shows you the rolling log. This is helpful for troubleshooting.

Log

Plugin Screen

This shows you the currently installed plugins and allows you to install, remove and upgrade plugins.

Log

When installing, removing or upgrading plugins the output is show in the browser to help troubleshoot any issues.

Log

Configuration Screen

And finally the configuration screen allows you to modify your Homebridge settings and your platforms and accessories.

Config

Supported Browsers

The following browsers are supported by this plugin:

  • Safari >= 10
  • Chrome >= 55 (including Opera)
  • FireFox >= 58
  • MS Edge >= 13 on the desktop
  • iOS >=10 and Chrome on mobile

MS Internet Explorer (any version) is not supported!

Contributing

Please see CONTRIBUTING.md.

Troubleshooting

1. Errors during installation

Make sure you installed the package with sudo and used the --unsafe-perm flag. Most installation errors can be fixed by removing the plugin and reinstalling:

# cleanup
sudo npm uninstall -g homebridge-config-ui-x

# reinstall
sudo npm install -g --unsafe-perm homebridge-config-ui-x

2. Accessories tab missing

If the Accessories tab is not show then you are not running Homebridge in insecure mode. See the Enabling Accessory Control wiki for details. If you have just enabled insecure mode make sure you have restarted Homebridge and refreshed the page in your browser.

3. Ask on Slack

Slack Status

Join the Homebridge Slack chat and ask in the #ui channel.