# Docker image using node16

**URL:** https://discourse.nodered.org/t/docker-image-using-node16/84176
**Category:** General
**Tags:** docker
**Created:** [1 January 2024 12:14 UTC](https://discourse.nodered.org/t/docker-image-using-node16/84176 "2024-01-01T12:14:51Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![cymplecy](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cymplecy/32/2773_2.png) [@cymplecy](https://discourse.nodered.org/u/cymplecy)
#### Post date: [1 January 2024 12:14 UTC](https://discourse.nodered.org/t/docker-image-using-node16/84176/1 "2024-01-01T12:14:51Z")

</div>

While investigating an issue with Blockly - it only seems to happen if its running in Docker.

> <https://github.com/bartbutenaers/node-red-contrib-blockly/issues/126#issuecomment-1872565210>
>
> Hi, I just tried out the Blockly node and I like the concept. But I have the iss…ue you can see in the gif. When I click on something where I would expect a div switching for an editable component the node instead starts dragging and I can not drop it anymore without closing the editor. 
> 
> !\[Node\_Red\_Blockly\_Text\_Box\_Click\](https://github.com/bartbutenaers/node-red-contrib-blockly/assets/2019114/47b4a73b-b0b3-4367-887f-2311acc6a238)
> 
> The Javascript console gives the following error:
> !\[image\](https://github.com/bartbutenaers/node-red-contrib-blockly/assets/2019114/b646aa1e-70a4-4abd-a0f9-577b9d726e44)
> 
> NodeRed version is 3.1.3 and node-red-contrib-blockly at 2.4.0
> Happens with Firefox and Chrome. Any Ideas?

So I installed Docker image on my Pi5 and noticed that it uses node.js 16

```auto
Welcome to Node-RED
===================

1 Jan 12:10:18 - [info] Node-RED version: v3.1.3
1 Jan 12:10:18 - [info] Node.js version: v16.20.2
1 Jan 12:10:18 - [info] Linux 6.1.0-rpi7-rpi-2712 arm64 LE
1 Jan 12:10:18 - [info] Loading palette nodes
1 Jan 12:10:19 - [info] Settings file : /data/settings.js
1 Jan 12:10:19 - [info] Context store : 'default' [module=memory]
1 Jan 12:10:19 - [info] User directory : /data
1 Jan 12:10:19 - [warn] Projects disabled : editorTheme.projects.enabled=false
1 Jan 12:10:19 - [info] Flows file : /data/flows.json
1 Jan 12:10:19 - [info] Server now running at http://127.0.0.1:1880/
1 Jan 12:10:19 - [warn] 

```

I've no idea if this is the cause but just wondering if the Docker image is up-to-date?

---

<div class="post-metadata">

### Author: ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)
#### Post date: [1 January 2024 12:22 UTC](https://discourse.nodered.org/t/docker-image-using-node16/84176/2 "2024-01-01T12:22:57Z")

</div>

Yes it is. (V4 will support node 20 and 18)

---

<div class="post-metadata">

### Author: ![cymplecy](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cymplecy/32/2773_2.png) [@cymplecy](https://discourse.nodered.org/u/cymplecy)
#### Post date: [1 January 2024 13:04 UTC](https://discourse.nodered.org/t/docker-image-using-node16/84176/3 "2024-01-01T13:04:08Z")

</div>

My follow up is then - is it possible to upgrade the node.js version inside of container that I'm running to see if that is the cause of the Blockly issue?

---

<div class="post-metadata">

### Author: ![UnborN](https://avatars.discourse-cdn.com/v4/letter/u/4491bb/32.png) [@UnborN](https://discourse.nodered.org/u/UnborN)
#### Post date: [1 January 2024 13:51 UTC](https://discourse.nodered.org/t/docker-image-using-node16/84176/4 "2024-01-01T13:51:52Z")

</div>

I dont use Docker but from i read in the **[Image Variations](https://github.com/node-red/node-red-docker#image-variations)** section of the node-red docker docs  
the version of nodejs depends on the image `tag` that you use to spin up the container.

For example if you use

```auto
docker run -it -p 1880:1880 -v node_red_data:/data --name mynodered nodered/node-red:latest-minimal

```

using the `latest-minimal` tag comes with nodejs version 16

but you have a list of different image tags like `3.1.3-18` that comes with nodejs 18

---

<div class="post-metadata">

### Author: ![cymplecy](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/cymplecy/32/2773_2.png) [@cymplecy](https://discourse.nodered.org/u/cymplecy)
#### Post date: [1 January 2024 14:57 UTC](https://discourse.nodered.org/t/docker-image-using-node16/84176/5 "2024-01-01T14:57:05Z")

</div>

Thanks - did that and it loads V18 (didn't make any diff to the issue I was testing but at least it's not down to the node.js version 🙂

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)
#### Post date: [15 January 2024 14:57 UTC](https://discourse.nodered.org/t/docker-image-using-node16/84176/6 "2024-01-15T14:57:31Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
