Giter VIP home page Giter VIP logo

Comments (4)

daffl avatar daffl commented on July 19, 2024

If you set NODE_ENV=production it will always load production.json. Are you sure the NODE_ENV environment variable is set to production?

from authentication-oauth2.

ImreC avatar ImreC commented on July 19, 2024

Yes, I am absolutely sure. To complete the technical information above I am using PM2 to run the node instance with the following ecosystem.json
{
"apps" : [{
"name" : "myapp",
"script" : "src/index.js",
"env": {
"NODE_ENV": "development"
},
"env_production" : {
"NODE_ENV": "production"
},
"env_staging" : {
"NODE_ENV" : "staging",
"TEST" : true
}
}]
}

The environment is set to production and the log says it is running at the host as defined in production.json. However, callback of github (and facebook) goes wrong if the host is not set in default.json too. Somehow the callback URL is generated from default.json. I am quite sure about this.

from authentication-oauth2.

daffl avatar daffl commented on July 19, 2024

What does the console output on the server look like when setting DEBUG=feathers:configuration?

from authentication-oauth2.

ImreC avatar ImreC commented on July 19, 2024

Ok, I had the same problem again with a new app. Ran in production mode, but the host was taken from default.json. Changed the default.json host to the production parameter. Then back to localhost. After that, it all worked. Debug output was also normal. Tried to reproduce it with a newly created test app. Wasn't able to reproduce the error with that. I have no clue what went wrong. Maybe close the issue. I will request a reopen if I ever find out what the problem was.

from authentication-oauth2.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.