skaffold-auth

1.0.3 • Public • Published

SKAFFOLD-AUTH

Skaffold-auth is the authentication plugin for a skaffolded application.

STEPS TO INSTALL

  • run the command npm install skaffold-auth from your terminal.
  • add the following code to your project
    var PassportLocalService = require('skaffold-auth').AuthenticationService.PassportLocalService;
    var authenticationService = new PassportLocalService();
    app.use(authenticationService._passport.initialize()); app.use(authenticationService._passport.session());
  • use the following code as a middleware in your routes
    authenticationService._passport.authenticate('local', authenticationService._behaviour)

Voila your authentication has been plugged-in Happy coding ;)

Readme

Keywords

Package Sidebar

Install

npm i skaffold-auth

Weekly Downloads

2

Version

1.0.3

License

MIT

Last publish

Collaborators

  • grantfayvor