infra/home/cluster/nodered/AUTH.md
2025-10-06 09:17:32 -05:00

1.3 KiB

Node-RED Authentication

Current Configuration

Node-RED is configured with authentication enabled:

  • Username: admin
  • Password: changeme

Changing the Password

  1. Edit the generate-password.yaml file and change the PASSWORD value
  2. Run the password generator:
    kubectl delete job nodered-password-generator -n nodered
    kubectl apply -f generate-password.yaml
    kubectl logs job/nodered-password-generator -n nodered
    
  3. Copy the generated hash
  4. Edit settings-configmap.yaml and replace the password hash
  5. Apply the changes:
    kubectl apply -f settings-configmap.yaml
    kubectl rollout restart deployment/nodered -n nodered
    

Adding More Users

Edit the settings-configmap.yaml file and add more users to the users array:

users: [{
    username: "admin",
    password: "$2b$08$...", 
    permissions: "*"
}, {
    username: "viewer",
    password: "$2b$08$...", 
    permissions: "read"
}]

Permissions can be:

  • * - Full access
  • read - Read-only access

Securing HTTP Nodes (Optional)

To also secure HTTP endpoints created in Node-RED flows, uncomment the httpNodeAuth line in settings-configmap.yaml.

Disabling Authentication

To disable authentication, remove or comment out the adminAuth section in settings-configmap.yaml.