lhw455 Posted April 15, 2016 Share Posted April 15, 2016 Thanks, the client ID error is because I used the default config which dosen't allow anon connections and I was trying without a username and password. I didn't even check past that point because I could clearly see that in the new location it's picking up the config file, but I can test it further if you like. Quote Link to comment
lhw455 Posted April 15, 2016 Share Posted April 15, 2016 Oh, and is there a way I can see the code behind the docker? I'm not a coder, but I can maybe try and help troubleshoot? *edit* some detective work (well for me anyway) and I've found the following code from your Github FROM debian:stable MAINTAINER Thomas Kerpe <[email protected]> RUN apt-get update RUN apt-get upgrade -y RUN apt-get install -y wget RUN wget -O - http://repo.mosquitto.org/debian/mosquitto-repo.gpg.key | apt-key add - RUN wget -O /etc/apt/sources.list.d/mosquitto-repo.list http://repo.mosquitto.org/debian/mosquitto-repo.list RUN apt-get update && apt-get install -y mosquitto RUN adduser --system --disabled-password --disabled-login mosquitto COPY config /mqtt/config VOLUME ["/mqtt/config", "/mqtt/data", "/mqtt/log"] EXPOSE 1883 CMD /usr/sbin/mosquitto -c /mqtt/config/mosquitto.conf It appears from my (admittedly newbie) logic that a user called moquitto gets added to the docker file and then the service runs as that user? Following that, maybe that user dosen't have the right permissions? I looked through some other Docker examples and it appears that this may not be needed i.e. just let the docker run as the default user? Alternatively, I noticed from here (https://github.com/toke/docker-mosquitto/blob/master/Dockerfile) that this is the Dockerfile: FROM debian:jessie MAINTAINER Thomas Kerpe <[email protected]> RUN apt-get update && apt-get install -y wget && \ wget -q -O - https://repo.mosquitto.org/debian/mosquitto-repo.gpg.key | apt-key add - && \ wget -q -O /etc/apt/sources.list.d/mosquitto-jessie.list https://repo.mosquitto.org/debian/mosquitto-jessie.list && \ apt-get update && apt-get install -y mosquitto && \ adduser --system --disabled-password --disabled-login mosquitto RUN mkdir -p /mqtt/config /mqtt/data /mqtt/log COPY config /mqtt/config RUN chown -R mosquitto:mosquitto /mqtt VOLUME ["/mqtt/config", "/mqtt/data", "/mqtt/log"] EXPOSE 1883 9001 CMD /usr/sbin/mosquitto -c /mqtt/config/mosquitto.conf So maybe we need the mosqitto user to own the files in the docker image? Apologies if I'm completely off-base here! Quote Link to comment
spants Posted April 16, 2016 Author Share Posted April 16, 2016 that is not my version :-) I will upload my templates to github later today. Quote Link to comment
mezz64 Posted April 19, 2016 Share Posted April 19, 2016 Would you be able to include the node-red-node-pushover module to the NodeRed docker? I've been adding it myself every time I update, but it may be useful to others as well. Thanks! Quote Link to comment
spants Posted April 20, 2016 Author Share Posted April 20, 2016 You can add the node-red-node-pushover node via the admin tab and it should persist between updates...... edit the node-red-contrib by using backspace. (is this how you are doing it?.... make sure that you are also pointing /data to a directory on your drives - in my case /mnt/user/docker/appdata/nodered so that the flows and additions persist) Quote Link to comment
mezz64 Posted April 21, 2016 Share Posted April 21, 2016 You can add the node-red-node-pushover node via the admin tab and it should persist between updates...... edit the node-red-contrib by using backspace. (is this how you are doing it?.... make sure that you are also pointing /data to a directory on your drives - in my case /mnt/user/docker/appdata/nodered so that the flows and additions persist) I had been doing it by opening a bash shell through "docker exec -it" on the container, didn't realize it could be done through the admin tab for some reason, but I've not switched to that method. I do have my /data directory mapped correctly, so I guess we'll see if it persists the next time I need to update. Quote Link to comment
beire Posted April 21, 2016 Share Posted April 21, 2016 Yeah adding through the admin Tab works great! No need to do any command line to add a node. Sent from my Nexus 6 using Tapatalk Quote Link to comment
spants Posted April 24, 2016 Author Share Posted April 24, 2016 MQTT docker updated/re-written to Mosquitto 1.4.8 + websockets. I found that the Home-Assistant docker wouldn't work with the old MQTT docker - the new update works! (I think it was the old version of Mosquitto that had problems) Quote Link to comment
lhw455 Posted April 28, 2016 Share Posted April 28, 2016 I tried the new one, same error as the old docker unfortunately. Tried experimenting a little bit more, what I found is that if I invoke the docker at the command line with different PGID and PUID I can read the config file fine, however it then complains that it can't find user mosquitto. Don't know if that helps with troubleshoting at all. Quote Link to comment
spants Posted April 29, 2016 Author Share Posted April 29, 2016 I tried the new one, same error as the old docker unfortunately. Tried experimenting a little bit more, what I found is that if I invoke the docker at the command line with different PGID and PUID I can read the config file fine, however it then complains that it can't find user mosquitto. Don't know if that helps with troubleshoting at all. Yes, thanks! I think that it is because you are using the /mnt/ and not /mnt/user/ hierarchy ..... I tested with the data on the protected raid and not on a cache drive. I will try and look at this over the weekend. Can I check that you really want to have your data stored in this way?. If you create a share that is only on one disk then it is that disk and parity that will be spinning. There is not a lot of energy difference and the strain on a disk is when it is starting up. Quote Link to comment
lhw455 Posted April 29, 2016 Share Posted April 29, 2016 Thanks, I did some more research on having the docker image and config files on the cache drive, and it's definitely the way I want to stay. But don't change your docker just for me! I just thought I'd try and help with troubleshooting as I'm sure there must be others who have a similar setup as me and maybe want the MQTT docker. Quote Link to comment
johngc Posted May 1, 2016 Share Posted May 1, 2016 Thanks, I did some more research on having the docker image and config files on the cache drive, and it's definitely the way I want to stay. But don't change your docker just for me! I just thought I'd try and help with troubleshooting as I'm sure there must be others who have a similar setup as me and maybe want the MQTT docker. +1 from me. I'm new to unRaid, Dockers and Home Assistant so am learning everyday. I have just found this docker though and now I understand what it does, I am struggling to get it to work but from reading this it appears that it is because I store my docker file on my cache disk at /mnt/cache/appdata/ too. Would be great if it could work at this location. However if not, how easy is it to move my docker file (and will it mess up all my configs??) Quote Link to comment
spants Posted May 1, 2016 Author Share Posted May 1, 2016 I've just totally rebuilt the MQTT docker to use Alpine Linux 3.3 - which is the version of Linux favoured by the Docker team. I have removed all the fancy Nobody/User settings as the have caused problems to me when I wanted to use the same docker on my mac. The issue will be is that to edit the settings on first use - defaults are created - you may need to run a NEWPERMS on the data directory. If you already have run the older version, it can use the settings but there is an updated EXAMPLE file that might be a better base: it shows the connects in the log window but doesnt create a huge logfile. For non mnt/user/ this may work better for you. *** Please let me know if it works or breaks something!!! *** (Note: that you will need the 1st May version - not the April) Quote Link to comment
johngc Posted May 1, 2016 Share Posted May 1, 2016 Spants, you are a legend. I had to remove the old docker and directory for it to work. I did just try pulling the new build first and then running a NEWPERMS on the cache but it didn't work so I just removed everything and started again and it has connected from mqtt-spy on my Macbook to my unRaid server just fine. Now to have a play with OwnTracks and HomeAssist and see how I get on. Very happy - thank you. Quote Link to comment
lhw455 Posted May 1, 2016 Share Posted May 1, 2016 Legend X 2, working for me too, thanks! Quote Link to comment
spants Posted May 16, 2016 Author Share Posted May 16, 2016 I have updated the NodeRed docker to allow the easy updating of the Nodes to the latest versions without me updating the Docker. To do this, I removed them from the build - you can reinstall them in the Admin tab (top right). Your flows will need you to re add the missing nodes that are used. The affected Nodes are: node-red-contrib-ibmpush node-red-contrib-googlechart node-red-contrib-nest node-red-contrib-splitter json-db-node-red node-red-contrib-freeboard node-red-contrib-sunevents node-red-node-badwords node-red-node-exif node-red-node-geofence node-red-node-mysql node-red-node-ping node-red-node-wol node-red-node-web-nodes node-red-node-base64 node-red-node-geohash node-red-node-twilio node-red-node-pushbullet node-red-node-aws node-red-contrib-ibm-watson-iot node-red-contrib-timeseries node-red-node-emoncms node-red-contrib-hue node-red-contrib-blynk node-red-contrib-pebble-watch node-red-node-twitter node-red-contrib-graphs node-red-contrib-influxdb node-red-contrib-bigtimer node-red-contrib-firebase node-red-contrib-ui node-red-contrib-admin node-red-node-smooth node-red-contrib-scx-ibmiotapp node-red-contrib-json node-red-contrib-eibd Quote Link to comment
beire Posted May 16, 2016 Share Posted May 16, 2016 Is there an update function for the admin tab? Or is updating done by removing and readding? Sent from my Nexus 6 using Tapatalk Quote Link to comment
spants Posted May 16, 2016 Author Share Posted May 16, 2016 I don't think that you can for that Node.... It needs to be installed by NPM Quote Link to comment
beire Posted May 17, 2016 Share Posted May 17, 2016 I wasn't very clear i think. I meant an update function in the admin tab for the other nodes. Sent from my Nexus 6 using Tapatalk Quote Link to comment
spants Posted May 17, 2016 Author Share Posted May 17, 2016 ah. I understand. There isn't an upgrade button. As far as I know, uninstalling and reinstalling should bring down the latest version. Thats a good point though - I hope that it doesnt just use the cached version!. I will ping the author of the Admin node. Quote Link to comment
spants Posted June 20, 2016 Author Share Posted June 20, 2016 Updated NodeRed to v0.14.2.... Quote Link to comment
beire Posted June 20, 2016 Share Posted June 20, 2016 Updated NodeRed to v0.14.2.... Hmmm. This update seems to fail. It completes fine but afterwards the nodered status sais "not available" instead of up-to-date. The container runs but is still at 13.4 I'm Running beta 23 Quote Link to comment
spants Posted June 20, 2016 Author Share Posted June 20, 2016 strange, running great here. I tried a push again and nothing else was uploaded... I wonder if docker is mid update for this docker. Try removing the docker and reinstalling. I will keep an eye out whilst watching the England game Quote Link to comment
beire Posted June 20, 2016 Share Posted June 20, 2016 I removed the docker incl. image. Now it won't reinstall. Getting following error: docker: layers from manifest don't match image configuration. Any idea? edit: found aptalca had a similar issue here: https://lime-technology.com/forum/index.php?topic=39413.675 Quote Link to comment
spants Posted June 20, 2016 Author Share Posted June 20, 2016 just done a complete rebuild with --no_cache, try again Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.