• Home
  • Categories
  • Recent
  • Popular
  • Tags
  • Users
  • Groups
  • Documentation
    • Home
    • Read API
    • Write API
    • Plugin Development
Skins
  • Light
  • Default
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Quartz
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Slate
  • Solar
  • Superhero
  • Vapor
Collapse

Community

Mr. OrangeM

Mr. Orange

@Mr. Orange
About
Posts
6
Topics
1
Groups
0
Followers
0
Following
0

Posts

Recent Best Controversial

    Disabled local login, and new default oauth instead of choice
  • Mr. OrangeM Mr. Orange

    @baris

    OAuth.init = function(data, callback) {
    	data.router.get('/login', function(req, res) {
            res.redirect('/auth/cws'); 		
    	});
    	callback(null, data);
    };
    

  • Disabled local login, and new default oauth instead of choice
  • Mr. OrangeM Mr. Orange

    @baris Thanks! I implemented this and it seems to be working. When I go to the address manually (e.g. by typing it in the url bar) the redirect works flawlessly, but when I press the login button on the homepage it keeps redirecting me to the choice screen? What am I doing wrong?


  • Disabled local login, and new default oauth instead of choice
  • Mr. OrangeM Mr. Orange

    Can anyone help me?


  • Disabled local login, and new default oauth instead of choice
  • Mr. OrangeM Mr. Orange

    That I understood, ;-). But doesn't seem to work, I added the following to hooks object in plugins.json:

    { "hook": "static:app.init", "method": "init"}
    

    And I then proceeded to add your suggested code to the library.js file, but as far as I can tell it doesn't seem to be executed? What am I doing wrong?


  • Disabled local login, and new default oauth instead of choice
  • Mr. OrangeM Mr. Orange

    Awesome, am I correct to assume that this also works for the registration and logout urls?


  • Disabled local login, and new default oauth instead of choice
  • Mr. OrangeM Mr. Orange

    I have a question regarding the login button in NodeBB. I've currently disabled the local login, and I have created a custom oauth using the sso example plugin. I am planning to only allow this custom SSO solution, but now that i've disabled the local login, it still gives me an option screen to choose logins, instead instantly going for the only option available.

    Can this be fixed by redirecting to my custom sso-auth solution immediately, instead of letting the user choose the only option available?

  • Login

  • Don't have an account? Register

  • Login or register to search.
Powered by NodeBB Contributors
  • First post
    Last post
0
  • Home
  • Categories
  • Recent
  • Popular
  • Tags
  • Users
  • Groups
  • Documentation
    • Home
    • Read API
    • Write API
    • Plugin Development
  • Login

  • Don't have an account? Register

  • Login or register to search.