description |
---|
Authenticate users via GitLab OAuth |
import Gitlab from "/traffic-policy/actions/oauth/examples/custom-gitlab-example.mdx"; import UpdatePolicyInstructions from "/traffic-policy/actions/oauth/update-policy/update-policy-instructions.mdx";
The step-by-step instructions below follow GitLab's documentation on setting up OAuth 2.0 for a web application.
-
Access your GitLab profile page and select Applications on the left menu.
Note: If you want to restrict the list of users able to log in with GitLab, either create an application under one of your groups or an instance-wide application. See Additional application setup information.
-
Provide a Name for your application and enter
https://idp.ngrok.com/oauth2/callback
in the Redirect URI field. -
In the Scopes section, select all the fields appropriate for your app and then click Save application. In this example, mark the openid, profile, and email fields.
<UpdatePolicyInstructions policySnippet={} />