# Node-Red container won't restart after adding a node

**URL:** <https://discourse.nodered.org/t/node-red-container-wont-restart-after-adding-a-node/37148>\
**Category:** General\
**Created:** [7 December 2020 20:29 UTC](https://discourse.nodered.org/t/node-red-container-wont-restart-after-adding-a-node/37148 "2020-12-07T20:29:08Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Kenspot](https://avatars.discourse-cdn.com/v4/letter/k/848f3c/32.png) [@Kenspot](https://discourse.nodered.org/u/Kenspot)\
**Post date:** [7 December 2020 20:29 UTC](https://discourse.nodered.org/t/node-red-container-wont-restart-after-adding-a-node/37148/1 "2020-12-07T20:29:09Z")

</div>

Node-Red Docker container won't restart after adding a node

I'm hoping that someone can help me, perhaps someone who uses Docker has had the same problem.

I was playing about adding a Node for IFTTT, and left a port for '80' in the config. Since doing this, the Container crashed and I cannot restart the Container. Is there a way to recover from this?

## I get the following log....

```auto
Your flow credentials file is encrypted using a system-generated key.

If the system-generated key is lost for any reason, your credentials

file will not be recoverable, you will have to delete it and re-enter

your credentials.

You should set your own key using the 'credentialSecret' option in

your settings file. Node-RED will then re-encrypt your credentials

file using your chosen key the next time you deploy a change.

---------------------------------------------------------------------

7 Dec 20:08:17 - [info] Starting flows

7 Dec 20:08:17 - [info] Added IFTTT express routes.

7 Dec 20:08:17 - [info] [ifttt-broker:MyWebHook] IFTTT broker listening on port 80

7 Dec 20:08:18 - [info] Started flows

7 Dec 20:08:18 - [red] Uncaught Exception:

7 Dec 20:08:18 - Error: listen EACCES: permission denied 0.0.0.0:80

    at Server.setupListenHandle [as _listen2] (net.js:1263:19)

    at listenInCluster (net.js:1328:12)

    at Server.listen (net.js:1415:7)

    at Function.listen (/data/node_modules/express/lib/application.js:618:24)

    at new IFTTTBrokerNode (/data/node_modules/node-red-contrib-ifttt-broker/ifttt-broker.js:42:29)

    at Object.createNode (/usr/src/node-red/node_modules/@node-red/runtime/lib/nodes/flows/util.js:483:31)

    at Flow.start (/usr/src/node-red/node_modules/@node-red/runtime/lib/nodes/flows/Flow.js:167:44)

    at start (/usr/src/node-red/node_modules/@node-red/runtime/lib/nodes/flows/index.js:345:33)

    at tryCatchReject (/usr/src/node-red/node_modules/when/lib/makePromise.js:845:30)

    at runContinuation1 (/usr/src/node-red/node_modules/when/lib/makePromise.js:804:4)

npm ERR! code ELIFECYCLE

npm ERR! errno 1

npm ERR! node-red-docker@1.0.5 start: `node $NODE_OPTIONS node_modules/node-red/red.js $FLOWS "--userDir" "/data"`

npm ERR! Exit status 1

npm ERR! 

npm ERR! Failed at the node-red-docker@1.0.5 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! /usr/src/node-red/.npm/_logs/2020-12-07T20_08_18_048Z-debug.log

> node-red-docker@1.0.5 start /usr/src/node-red

> node $NODE_OPTIONS node_modules/node-red/red.js $FLOWS "--userDir" "/data"

7 Dec 20:08:46 - [info] 

Welcome to Node-RED

===================

7 Dec 20:08:46 - [info] Node-RED version: v1.0.5

7 Dec 20:08:46 - [info] Node.js version: v10.20.0

7 Dec 20:08:46 - [info] Linux 5.0.0-32-generic x64 LE

7 Dec 20:08:46 - [info] Loading palette nodes

7 Dec 20:08:47 - [info] Dashboard version 2.20.0 started at /ui

7 Dec 20:08:47 - [info] Settings file : /data/settings.js

7 Dec 20:08:47 - [info] Context store : 'default' [module=memory]

7 Dec 20:08:47 - [info] User directory : /data

7 Dec 20:08:47 - [warn] Projects disabled : editorTheme.projects.enabled=false

7 Dec 20:08:47 - [info] Flows file : /data/flows.json

7 Dec 20:08:47 - [info] Server now running at http://127.0.0.1:1880/

7 Dec 20:08:47 - [warn]

```

---

<div class="post-metadata">

**Author:** ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)\
**Post date:** [7 December 2020 20:48 UTC](https://discourse.nodered.org/t/node-red-container-wont-restart-after-adding-a-node/37148/2 "2020-12-07T20:48:51Z")

</div>

I am not up to speed on docker but if you can add a startup parammeter you could add `--safe` to start up node-red in safe mode.

alternatively if you can access the file system, you could rename the xxx\_flow.json file and restart - this way node-red wont load and run your flow.

---

<div class="post-metadata">

**Author:** ![Kenspot](https://avatars.discourse-cdn.com/v4/letter/k/848f3c/32.png) [@Kenspot](https://discourse.nodered.org/u/Kenspot)\
**Post date:** [18 January 2021 10:42 UTC](https://discourse.nodered.org/t/node-red-container-wont-restart-after-adding-a-node/37148/3 "2021-01-18T10:42:35Z")

</div>

Hi Steve, thanks for the reply - I didn't realise I had one!  
I managed to find where the docker files where, I got it working again by deleting the ‘.flows.json’ file and renaming the ‘.flows.json.backup’ to ‘.flows.json'.

---

<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:** [19 March 2021 10:43 UTC](https://discourse.nodered.org/t/node-red-container-wont-restart-after-adding-a-node/37148/4 "2021-03-19T10:43:08Z")

</div>

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