# Cant set auth for Node-red at Render

**URL:** <https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528>\
**Category:** General\
**Created:** [11 April 2025 22:02 UTC](https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528 "2025-04-11T22:02:12Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![yarikshark](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/yarikshark/32/100091_2.png) [@yarikshark](https://discourse.nodered.org/u/yarikshark)\
**Post date:** [11 April 2025 22:02 UTC](https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528/1 "2025-04-11T22:02:12Z")

</div>

Hello everyone, im trying to deploy Node-red on [render.com](http://render.com) at free instance as web service, using as source github repository ([GitHub - yarickshark/Node-red](https://github.com/yarickshark/Node-red)), but i cant set authorization. I just uncommented part of "settings.js" - adminAuth.  
Deployed same files locally on pc with windows - everything work as it should (authorization works). When i do the same deploying at render - there is no authorization, just node-red web.  
How to make authorization work?

node-red version 4.0.9

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [12 April 2025 07:33 UTC](https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528/2 "2025-04-12T07:33:15Z")

</div>

Are you able to see the node red startup log?

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [12 April 2025 14:27 UTC](https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528/3 "2025-04-12T14:27:13Z")

</div>

Your repo only contains the userDir folder. How have you installed Node-RED itself? And how do you run it?

---

<div class="post-metadata">

**Author:** ![yarikshark](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/yarikshark/32/100091_2.png) [@yarikshark](https://discourse.nodered.org/u/yarikshark)\
**Post date:** [12 April 2025 20:11 UTC](https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528/4 "2025-04-12T20:11:23Z")

</div>

Installed node.js, installed node-red on pc (C:...), started, set auth.  
Copied to D:..., made a local repo from copy, pushed to github. At render set repo to use for deploy, and its live, but without auth

---

<div class="post-metadata">

**Author:** ![yarikshark](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/yarikshark/32/100091_2.png) [@yarikshark](https://discourse.nodered.org/u/yarikshark)\
**Post date:** [12 April 2025 20:13 UTC](https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528/5 "2025-04-12T20:13:39Z")

</div>

Yes, here logs from render:

> **Logs**
>
> ```auto
> 12 Apr 20:02:23 - [info] Stopped flows
> 
> Apr 12 11:03:33 PM12 Apr 20:03:33 - [info] Linux 6.8.0-1024-aws x64 LE
> 
> Apr 12 11:03:34 PM12 Apr 20:03:34 - [info] Loading palette nodes
> 
> Apr 12 11:03:38 PM12 Apr 20:03:38 - [info] Settings file : /opt/render/.node-red/settings.js
> 
> Apr 12 11:03:38 PM12 Apr 20:03:38 - [info] Context store : 'default' [module=memory]
> 
> Apr 12 11:03:38 PM12 Apr 20:03:38 - [info] User directory : /opt/render/.node-red
> 
> Apr 12 11:03:38 PM12 Apr 20:03:38 - [warn] Projects disabled : editorTheme.projects.enabled=false
> 
> Apr 12 11:03:38 PM12 Apr 20:03:38 - [info] Flows file : /opt/render/project/src/flows.json
> 
> Apr 12 11:03:38 PM12 Apr 20:03:38 - [warn]
> 
> Apr 12 11:03:38 PM
> 
> Apr 12 11:03:38 PM---------------------------------------------------------------------
> 
> Apr 12 11:03:38 PMYour flow credentials file is encrypted using a system-generated key.
> 
> Apr 12 11:03:38 PM
> 
> Apr 12 11:03:38 PMIf the system-generated key is lost for any reason, your credentials
> 
> Apr 12 11:03:38 PMfile will not be recoverable, you will have to delete it and re-enter
> 
> Apr 12 11:03:38 PMyour credentials.
> 
> Apr 12 11:03:38 PM
> 
> Apr 12 11:03:38 PMYou should set your own key using the 'credentialSecret' option in
> 
> Apr 12 11:03:38 PMyour settings file. Node-RED will then re-encrypt your credentials
> 
> Apr 12 11:03:38 PMfile using your chosen key the next time you deploy a change.
> 
> Apr 12 11:03:38 PM---------------------------------------------------------------------
> 
> Apr 12 11:03:38 PM
> 
> Apr 12 11:03:38 PM12 Apr 20:03:38 - [info] Server now running at http://127.0.0.1:10000/
> 
> Apr 12 11:03:38 PM12 Apr 20:03:38 - [warn] Encrypted credentials not found
> 
> Apr 12 11:03:38 PM12 Apr 20:03:38 - [info] Starting flows
> 
> Apr 12 11:03:38 PM12 Apr 20:03:38 - [info] Started flows
> 
> ```

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [12 April 2025 20:40 UTC](https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528/6 "2025-04-12T20:40:28Z")

</div>

Why is the settings file it is using not in the same folder as the flows file?

---

<div class="post-metadata">

**Author:** ![yarikshark](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/yarikshark/32/100091_2.png) [@yarikshark](https://discourse.nodered.org/u/yarikshark)\
**Post date:** [13 April 2025 19:41 UTC](https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528/7 "2025-04-13T19:41:17Z")

</div>

Is it should be? its installed on pc with windows that way...

Can it be that i installed node-red on windows pc, copied to repo, but render servers probably using linux?

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [13 April 2025 20:34 UTC](https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528/8 "2025-04-13T20:34:32Z")

</div>

On a normal install on Windows or on Linux they would both be in the user's .node-red folder. Also they are in the same folder in your github repo.

Which settings.js did you edit and have you checked that the one it is actually using has your edits in it?

---

<div class="post-metadata">

**Author:** ![yarikshark](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/yarikshark/32/100091_2.png) [@yarikshark](https://discourse.nodered.org/u/yarikshark)\
**Post date:** [14 April 2025 06:53 UTC](https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528/9 "2025-04-14T06:53:35Z")

</div>

Maybe i dont understand a question

I edited setings.js in browser in repo (that one, which not at folder, at pc it must be in .node-red folder), and than rebuint it at render (that must reload all files before deploy)

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [14 April 2025 07:35 UTC](https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528/10 "2025-04-14T07:35:23Z")

</div>

> [@yarikshark](#):
>
> Maybe i dont understand a question

I meant that you should look at the file `/opt/render/.node-red/settings.js` when node-red has started and check that it contains the admin auth changes.

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [14 April 2025 09:24 UTC](https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528/11 "2025-04-14T09:24:54Z")

</div>

> [@yarikshark](#):
>
> Can it be that i installed node-red on windows pc, copied to repo, but render servers probably using linux?

If you look on GitHub under my id, you will find an alternate installer for Node-RED that will do what you need. You don't have to run it if you don't want to but you can borrow the process and adapt for your own needs.

Instead of the "normal" install of Node-RED - which installs to a global location, you install it to a local folder and create a userDir folder inside that (userDir is where the settings and flows all go). That way, you have everything in a single parent folder.

You create a script entry in the parent package.json file so that `npm start` will run Node-RED directly which matches the instructions for running custom node.js apps from the [render.com](http://render.com) docs. You can use this as your start script (assumes that userDir will be in the `data` sub-folder, adjust as needed:

```auto
node node_modules/node-red/red.js --userDir ./data

```

---

<div class="post-metadata">

**Author:** ![yarikshark](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/yarikshark/32/100091_2.png) [@yarikshark](https://discourse.nodered.org/u/yarikshark)\
**Post date:** [26 April 2025 16:19 UTC](https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528/12 "2025-04-26T16:19:29Z")

</div>

Hello, even installed with this method, edited /Node-red/data/settings.js with authorization, deployed this on render and its still allowing to node-red dashboard without login

---

<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:** [25 July 2025 16:19 UTC](https://discourse.nodered.org/t/cant-set-auth-for-node-red-at-render/96528/13 "2025-07-25T16:19:51Z")

</div>

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