[support] Spants - NodeRed, MQTT, Dashing, couchDB


428 posts in this topic Last Reply

Recommended Posts

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.

Link to post
  • Replies 427
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Popular Posts

Ya....just go into the Node-Red Docker template and change the repository as I said above and hit apply.......That's all I had to do. Love it

This is where I will be hosting some dockers that I find useful, built on a Phusion or Linuxserver base. Add to your templates if you wish.   https://github.com/spants/unraidtemplates/

Does anyone here know how to update node.js version in the Node-Red Docker Container?   docker exec -it NodeRed-OfficialDocker /bin/bash node -V The command above shows I'm on v

Posted Images

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 <thomas@kerpe.net>


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 <toke@toke.de>


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!

Link to post

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)

Link to post

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.

Link to post

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)

Link to post

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.

Link to post

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.

Link to post

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.

Link to post
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??)

 

 

 

Link to post

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)

Link to post

Spants, you are a legend.  8)

 

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.

Link to post
  • 2 weeks later...

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

Link to post

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.

 

Link to post
  • 1 month later...

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

Link to post

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 :)

 

Link to post

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.