skip to Main Content

The entire settings file is the default settings file produced by node-red with the addition of

//COMMENT TEST HERE 
    adminAuth: require("./node_modules/node-red-contrib-okta/user-authentication")({
        oktaAPIToken: process.env.OKTA_TOKEN,
        oktaAPIUrl:  process.env.OKTA_URL,               //Okta API url
        groups: [
            {
                groupID: process.env.OKTA_GROUP_ID,    //okta group DD
                permissions: '*'
            }
        ]
    }),

When I include this code, I get this error

docker-node-red-web-1  | 2022-06-07T20:24:24: PM2 log: App [node-red:0] exited with code [0] via signal [SIGINT]
docker-node-red-web-1  | 2022-06-07T20:24:24: PM2 log: App [node-red:0] starting in -fork mode-
docker-node-red-web-1  | 2022-06-07T20:24:24: PM2 log: App [node-red:0] online

when I do not include it, everything works smoothly, what is going wrong?

I can include the authentication code if it helps anyone responding, but I doubt it’s really the route of the issue.

Thanks

2

Answers


  1. Chosen as BEST ANSWER

    The solution ended up being the location of certain directories!

    A Little bit hard to explain over text, but there had to be some stuff shuffled around.


  2. There isn’t enough information in the question to answer this.

    The settings.js needs to be a properly formatted JavaScript source file. The easiest way to test this is to manually load the settings file in nodejs.

    Assuming you have a local directory mounted as /data which contains the settings.js file, do the following

    • cd in to the volume directory
    • export all the required environment variables
    • run node
    • type require('./settings.js') and press enter

    This should give you a exact error message for what is wrong with your settings.js file

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search