Really wanted to get this to run locally in Docker on my Synology NAS, so I spent a bit of time on it last night.. and failed. Just needed a good night's sleep; gave it another 15 minutes and it works! I'm sharing in case anyone's interested.
The main issue I ran into was that getIPAddress() returns the IP of the container, which in my environment is not available from Hubitat. So I kludge'd it to return the IP of the host (and I'm not talking about the IP exposed by /sbin/ip route, which is still a docker land IP). The correct IP is actually the hostUrl. @tonesto7 maybe a "Docker?" checkbox in the Required Settings could set that as the IP instead of trying to get it from os.networkInterfaces? Or just add a field?
ssh admin@synology
(I have all my docker configs and volumes on volume2)
cd /volume2/docker
git clone GitHub - tonesto7/echo-speaks-server
vi echo-speaks-server/index.js
# ugly temporary hardcoded kludge
look for function getIPAddress()
on the first line: return 'your IP';
cd ~
mkdir echo-speaks-server
cd echo-speaks-server
vi docker-compose.yml
version: "2"
services:
node:
container_name: node-echo-speaks
restart: on-failure
image: "node:alpine"
working_dir: /home/node/app
environment:
- NODE_ENV=production
volumes:
- /volume2/docker/node-echo-speaks/:/home/node/app
ports:
- "8091:8091"
- "9222:9222"
- "9229:9229"
command: >
sh -c "npm install &&
npm start"
sudo docker-compose up -d
The container should now be running. Follow the usual installation instructions for Echo Speaks.
Really happy to finally have TTS after not being able to get it on my plethora of Google products!