nimblewillo - Hmm, I'm finding signalk as a doc...
Hmm, I'm finding signalk as a docker image to be annoying. The real point of docker is to disconnect the os dependencies from the app dependencies but it's always painful when I try running it in docker on ubuntu lts.
8 Replies
in my latest test case, it's complaining about the avahi interface and that node.js is not version 18. And it's not actually working to talk on port 3000
ubuntu 20.04 lts minimal server install, fully updated, docker-ce install to avoid ubuntu's lame docker repo
sounds weird. what image are you using?
and how are you launching it?
the Avahi Warnings are unfortunately not easily avoidable
how does
docker run --init -it --rm --name signalk-server --publish 3000:3000 --entrypoint /home/node/signalk/bin/signalk-server cr.signalk.io/signalk/signalk-server:v2.6.2 --sample-nmea0183-data
work for you?
i really don't understand how it would complain about node version - as you said, one of the points should be being self containedsudo docker run --rm signalk/signalk-server --publish 3000:3000
sudo docker run --init -it --rm --name signalk-server --publish 3000:3000 --entrypoint /home/node/signalk/bin/signalk-server cr.signalk.io/signalk/signalk-server:v2.6.2 --sample-nmea0183-data
[sudo] password for willo:
Unable to find image 'cr.signalk.io/signalk/signalk-server:v2.6.2' locally
v2.6.2: Pulling from signalk/signalk-server
Digest: sha256:6fff295d4c3c3e836af7409f5e46193b93b27127386d4f57fc99bdf4af7b88fb
Status: Downloaded newer image for cr.signalk.io/signalk/signalk-server:v2.6.2
The installed version of node (v20.11.1) is different than the recommended version (18). See https://github.com/SignalK/signalk-server/wiki/Installing-and-Updating-Node.js for more information how to upgrade.
Settings file does not exist, using empty settings
Using sample data from /usr/lib/node_modules/signalk-server/samples/plaka.log
Could not parse security config
ENOENT: no such file or directory, open '/home/node/.signalk/security.json'
Could not parse security config
ENOENT: no such file or directory, open '/home/node/.signalk/security.json'
WARNING The program 'node' uses the Apple Bonjour compatibility layer of Avahi.
WARNING Please fix your application to use the native API of Avahi!
WARNING For more information see http://0pointer.de/blog/projects/avahi-compat.html
WARNING The program 'node' called 'DNSServiceRegister()' which is not supported (or only supported partially) in the Apple Bonjour compatibility layer of Avahi.
WARNING Please fix your application to use the native API of Avahi!
WARNING For more information see http://0pointer.de/blog/projects/avahi-compat.html
Could not start mDNS:Error: dns service error: unknown
signalk-server running at 0.0.0.0:3000
It actually started up with that command
The command I was using failed to actually answer on port 3000
(That command is straight from the documentation)
Which command did not work and where is it in the docs? Hard to fix unless you give some hints…
Ah 🤦 about the node version! @Karl-Erik Gustafsson docker image is now on node v20, right?
Docker node using v20.
https://demo.signalk.org/documentation/installation/install.html
Using Docker
Signal K Server is available as a Docker image on Docker Hub and cr.signalk.io/signalk/signalk-server.
To simply run a Signal K Server with some sample data on a device with docker installed, enter the following into a terminal:
docker run --rm signalk/signalk-server --publish 3000:3000
The last line there is where things go awry
run that, things seem to start up, but no response on port 3000
I tested using wget on the docker host as well as browser from workstation
I actually saw this before but assumed it my install
I'm back home just trying to setup a test environment for sensor development
I would understand issues with plugins installed under v18 and mapped outside container. Reinstall will cure this, but all server core related are built during image creation and should not cause any issues. At least I haven't noticed.
Need to check when v20 upgrade happened, but it was already quite long time ago.
Edit: One month ago...
we are just internally inconsistent, complaining about anything that is not 18 https://github.com/SignalK/signalk-server/blob/a2ab14c180f85897f4817ab5a1730820878ecd35/bin/signalk-server#L27-L28
thanks, that was just plain wrong, docker arguments go before the image name. fixed in https://github.com/SignalK/signalk-server/commit/4ddd4e2cd00e6487c1fc434b848ff71d5fa867ef