Skip to content

Commit

Permalink
WIP: fix limitation of about 33 devices...
Browse files Browse the repository at this point in the history
Signed-off-by: Martin Buchleitner <[email protected]>
  • Loading branch information
mabunixda committed Jun 27, 2019
1 parent 97df226 commit 36466dc
Show file tree
Hide file tree
Showing 9 changed files with 977 additions and 505 deletions.
9 changes: 6 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
FROM nodered/node-red-docker:slim-v8
FROM nodered/node-red-docker:slim-v10

COPY docker-package.json /usr/src/node-red/package.json
COPY ./ /usr/src/alexa-node

USER root

RUN npm install \
&& npm link /usr/src/alexa-node/
## install custom deps
RUN npm install

## link dev code
RUN npm link /usr/src/alexa-node/

USER node-red

27 changes: 2 additions & 25 deletions alexa/alexa-helper.js
Original file line number Diff line number Diff line change
@@ -1,31 +1,8 @@
"use strict";

const alexa_controller = require('./alexa-home-controller');

module.exports = {
hubPort: process.env.ALEXA_PORT != undefined && parseInt(process.env.ALEXA_PORT) || 60000,
controllerNode: undefined,
controllerDynamic: true,
isDebug: process.env.DEBUG && process.env.DEBUG.indexOf("node-red-contrib-alexa-home") > 0 || false,
bri_default: process.env.BRI_DEFAULT || 126,
prefixUUID: "f6543a06-da50-11ba-8d8f-",
HUE_USERNAME: "1028d66426293e821ecfd9ef1a0731df",
nodeSubPath : ""
}

module.exports.formatUUID = function (lightId) {
if (lightId === null || lightId === undefined)
return "";

var string = ("" + lightId);
return string.replace(".", "").trim();
bri_default: process.env.BRI_DEFAULT || 126,
}

module.exports.formatHueBridgeUUID = function (lightId) {
if (lightId === null || lightId === undefined)
return "";
var uuid = module.exports.prefixUUID;
uuid += module.exports.formatUUID(lightId);
return uuid;
}


Loading

0 comments on commit 36466dc

Please sign in to comment.