Skip to content

Instantly share code, notes, and snippets.

View dhont's full-sized avatar

Dragos Hont dhont

  • bucharest, romania
View GitHub Profile
@oznu
oznu / index.js
Last active January 12, 2024 13:11
Homebridge Switch Plugin Example
'use strict'
let Service, Characteristic
module.exports = (homebridge) => {
/* this is the starting point for the plugin where we register the accessory */
Service = homebridge.hap.Service
Characteristic = homebridge.hap.Characteristic
homebridge.registerAccessory('homebridge-switch-example', 'SwitchExample', SwitchAccessory)
}
@HCanber
HCanber / Sinopia.md
Last active April 21, 2018 21:39
Host Sinopia in IIS on Windows

These instructions were written for Windows Server 2012, IIS 8, Node.js 0.12.3, iisnode 0.2.16 and Sinopia 1.3.1

  1. Install IIS
  2. Install iisnode. Make sure you install prerequisites (Url Rewrite Module & node) as explained in the instructions for iisnode
  3. Create a new folder in Explorer where you want to host Sinopia. For example C:\Sinopia. Save package.json, start.js and web.config in this folder.
  4. Create a new site in Internet Information Services Manager. You can name it whatever you want. I'll call it Sinopia in these instructions. Specify the path to where you saved all files and a port number.
  5. Go back to Explorer and give the user that runs the application pool modify rights to the folder you just created. If you've named the new site Sinopia and did not change the app pool, it's running und