matijse / eufy-ha-mqtt-bridge

Receive Eufy alerts and thumbnails in Home Assistant via MQTT
124 stars 25 forks source link

error: Cannot read config.yml #81

Closed broeredaan closed 3 years ago

broeredaan commented 3 years ago

Hello I'm trying to setup the bridge in a container but it cant seem to get it to read the config.yml I created

Seems to be a read issue or something but I don't know how to get better logs from this. Anyone able to clarify? This feels like an utter noob question but I just cant figure it out for some reason.

Thank you :)

Docker

/volume1/appdata/eufy-bridge/data | /app/data

config.yml

eufy:
  username: "mymail"
  password: "mypass"
mqtt:
  url: "mqtt://mqttip:1883"
  username: ""
  password: ""
  keepalive: 60
home_assistant:
  off_delay: 5

Error

> eufy-ha-mqtt-bridge@1.0.0 start /app
> NODE_ENV=production node --unhandled-rejections=strict index.js

error: Cannot read config.yml {"timestamp":"2021-07-06T09:42:06.099Z"}
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! eufy-ha-mqtt-bridge@1.0.0 start: `NODE_ENV=production node --unhandled-rejections=strict index.js`
npm ERR! Exit status 1
 

npm ERR! Failed at the eufy-ha-mqtt-bridge@1.0.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/node/.npm/_logs/2021-07-06T09_42_06_151Z-debug.log

image

image

image

MaxWinterstein commented 3 years ago

Sadly this issue is missing a lot of formatting which makes it hard to read :(
You might wan't to check out https://guides.github.com/features/mastering-markdown/ when time is available ✌️

Just to make sure, your config.yml is propperly formattet, right?

eufy:
  username: "mymail"
  password: "mypass"
mqtt:
  url: "mqtt://mqttip:1883"
  username: ""
  password: ""
  keepalive: 60
home_assistant:
  off_delay: 5

It looks like this, with the indentation?

broeredaan commented 3 years ago

@MaxWinterstein Thanks for the answer I have updated my comment with better formatting and screenshots. For the .yml I copied the example and filled by own data seems proper to me. But it just seems like its simply unable to read it somehow. I run it within docker synology and have given the file within chmod -R 777 just in case but no luck. Not sure how I can access the /home/node/.npm .... debug.log within a non-running docker container. That would probably give more info

MaxWinterstein commented 3 years ago

@broeredaan thanks for the work of formatting 👍

Mounting folders on synology docker is always a little ugly. And, the docker version used at DSM is pretty old.

To make sure there is no additional folder created, and after all those years in IT stuff like this happens to me too, i would recommend mounting just the config file for testing.

/volume1/appdata/eufy-bridge/data/config.yml -> /app/data/config.yml

broeredaan commented 3 years ago

@MaxWinterstein No luck still image Maybe I should look into not running docker on synology then. It does confuse me because I have docker containers running multiple things without fault image

broeredaan commented 3 years ago

Ah I removed the full folder volume binding and I did get a different message

> eufy-ha-mqtt-bridge@1.0.0 start /app
> NODE_ENV=production node --unhandled-rejections=strict index.js

(process:29): VIPS-WARNING **: 15:29:37.047: unable to load "/usr/lib/vips-modules-8.11/vips-heif.so" -- Error relocating /usr/lib/libheif.so.1: de265_get_image_full_range_flag: symbol not found
MaxWinterstein commented 3 years ago

The issue here is the 0.2.19 image. Try the 0.2.17 tag, it should work better.

See https://github.com/matijse/eufy-ha-mqtt-bridge/issues/76

MaxWinterstein commented 3 years ago

I guess, the bind must end with a slash to mount the data from the folder mentioned, not the folder itself at the mountpoint.

/app/data/data/config.yml vs /app/data/config.yml`

broeredaan commented 3 years ago

Changes to 0.2.17 and no more errors. I'll mess around with the bindings some more but issue is solved. Thank you :)