Giter Site home page Giter Site logo

cyrussuen / docker-homebridge Goto Github PK

View Code? Open in Web Editor NEW

This project forked from homebridge/docker-homebridge

0.0 1.0 0.0 10 KB

Homebridge Docker. HomeKit support for the impatient using Docker on x86_64 or Raspberry Pi (armhf).

Home Page: https://hub.docker.com/r/oznu/homebridge/

Shell 100.00%

docker-homebridge's Introduction

Docker Automated buil Docker Pulls GitHub release

Docker Homebridge

This Alpine Linux based Docker image allows you to run Nfarina's Homebridge on your home network which emulates the iOS HomeKit API.

Compatibility

Homebridge requires full access to your local network to function correctly which can be achieved using the --net=host flag. Currently this will not work when using Docker for Mac due to this issue.

Usage

Quick Setup:

docker run
  --net=host
  --name=homebridge
  -e TZ=<timezone>
  -v </path/to/config>:/homebridge
  oznu/homebridge

Raspberry Pi

This image will also run on a Raspberry Pi using the raspberry-pi tag:

docker run --net=host --name=homebridge oznu/homebridge:raspberry-pi

This docker image has been tested on the following Raspberry Pi models:

  • Raspberry Pi 1 Model B
  • Raspberry Pi 3 Model B
  • Raspberry Pi Zero W

Parameters

The parameters are split into two halves, separated by a colon, the left hand side representing the host and the right the container side.

  • --net=host - Shares host networking with container, required.
  • -v /homebridge - The Homebridge config and plugin location.
  • -e TZ - for timezone information eg Europe/London, etc

Config

The Homebridge config file is located at </path/to/config>/config.json This file will be created the first time you run the container with a sample FakeBulb accessory.

Plugins

Plugins should be defined in the </path/to/config>/package.json file in the standard NPM format. This file will be created the first time you run the container with the FakeBulb module.

Any plugins added to the package.json will be installed each time the container is restarted. Plugins can be uninstalled by removing the entry from the package.json and restarting the container.

You can also install plugins using yarn (an npm replacement) which will automatically update the package.json file as you add and remove modules.

You must restart the container after installing or removing plugins for the changes to take effect.

To add plugins using yarn:

docker exec <container name or id> yarn add <module name>

Example:

docker exec homebridge yarn add homebridge-hue

To remove plugins using yarn:

docker exec <container name or id> yarn remove <module name>

Example:

docker exec homebridge yarn remove homebridge-hue

Docker Compose

If you prefer to use Docker Compose:

version: '2'
services:
  homebridge:
    image: oznu/homebridge
    restart: always
    network_mode: host
    environment:
      - TZ=Australia/Sydney
    volumes:
      - ./volumes/homebridge:/homebridge

Troubleshooting

1. Verify your config.json and package.json syntax

Many issues appear because of invalid JSON. A good way to verify your config is to use the jsonlint.com validator.

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.