passport-gitlab

0.5.0 • Public • Published

Prerequisites

Gitlab >= 7.7

var GitlabStrategy = require('passport-gitlab').Strategy;

passport.use(new GitlabStrategy({
    clientID: GITLAB_APP_KEY,
    clientSecret: GITLAB_APP_SECRET,
    gitlabURL : "https://gitlab.example.com",
    callbackURL: "http://127.0.0.1:3000/auth/gitlab/callback"
  },
  function(token, tokenSecret, profile, done) {
    User.findOrCreate({ id: profile.id }, function (err, user) {
      return done(err, user);
    });
  }
));

Versions

Current Tags

  • Version
    Downloads (Last 7 Days)
    • Tag
  • 0.5.0
    113
    • latest

Version History

  • Version
    Downloads (Last 7 Days)
    • Published
  • 0.5.0
    113
  • 0.1.0
    1

Package Sidebar

Install

npm i passport-gitlab

Weekly Downloads

65

Version

0.5.0

License

none

Last publish

Collaborators

  • erik.seifert