A Gateway to Git APIs
Clone or download
calavera Merge pull request #18 from netlify/update-readme-gitlab
Update readme with GitLab instructions
Latest commit 1e8bce9 Jul 20, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.github First commit Aug 31, 2017
api Handle gzipped BitBucket responses Jul 20, 2018
cmd First commit Aug 31, 2017
conf Git Gateway support for BitBucket Jul 19, 2018
models First commit Aug 31, 2017
storage Do not run storage tests yet. Sep 6, 2017
.gitignore First commit Aug 31, 2017
.travis.yml First commit Aug 31, 2017
CODE_OF_CONDUCT.md First commit Aug 31, 2017
CONTRIBUTING.md First commit Aug 31, 2017
Dockerfile First commit Aug 31, 2017
LICENSE First commit Aug 31, 2017
Makefile First commit Aug 31, 2017
README.md added instructions about GitLab support Jun 8, 2018
app.json First commit Aug 31, 2017
example.env Update README Sep 5, 2017
glide.lock First commit Aug 31, 2017
glide.yaml First commit Aug 31, 2017
main.go First commit Aug 31, 2017
netlify.toml First commit Aug 31, 2017

README.md

git-gateway - Gateway to hosted git APIs

Secure role based access to the APIs of common Git Hosting providers.

When building sites with a JAMstack approach, a common pattern is to store all content as structured data in a Git repository instead of relying on an external database.

Netlify CMS is an open-source content management UI that allows content editors to work with your content in Git through a familiar content editing interface. This allows people to write and edit content without having to write code or know anything about Git, markdown, YAML, JSON, etc.

However, for most use cases you won’t want to require all content editors to have an account with full access to the source code repository for your website.

Netlify’s Git Gateway lets you setup a gateway to your choice of Git provider's API ( now available with both GitHub and GitLab 🎉 ) that lets tools like Netlify CMS work with content, branches and pull requests on your users’ behalf.

The Git Gateway works with any identity service that can issue JWTs and only allows access when a JSON Web Token with sufficient permissions is present.

To configure the gateway, see our example.env file

The Gateway limits access to the following sub endpoints of the repository:

for GitHub:

   /repos/:owner/:name/git/
   /repos/:owner/:name/contents/
   /repos/:owner/:name/pulls/
   /repos/:owner/:name/branches/

for GitLab:

   /repos/:owner/:name/files/
   /repos/:owner/:name/commits/
   /repos/:owner/:name/tree/