Hosting with GitLab

To host your Fern docs using GitLab, you will need to add a Fern token to your repository variables.

Add a token to GitLab

1

Log in

Log into GitLab.

3

Add variable

Scroll to the Variables section and select Expand > Add variable. Add your key and value, deselect Protect variable, and then click Save changes.

Preview docs with GitLab

1

Contact us

To get set up with a GitLab pipeline to preview your docs automatically, reach out via your dedicated Slack channel or email.

2

Log in

Log into GitLab.

4

Generate project access token

Click on Add new token. You then need to:

  • Add your token name
  • Select an expiry date (note: once the token expires, you will need to generate a new one)
  • Set role to Reporter
  • Set scope to api

When finished, click Create project access token.

Save your token

Be sure to save the generated token - it won’t be displayed after you leave the page.

5

Add token to repository variables

You can do this using the steps listed above.