oott123 / rawlab

Serves raw files from gitlab, with correct MIME types.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

RawLab

Serves raw files from gitlab, with correct MIME types.

Run

export GITLAB_API=https://gitlab.com/api/v4
export PORT=8888
./rawlab

or with docker:

docker run --rm -p 8625:8625 -e GITLAB_API=https://gitlab.com/api/v4 quay.io/oott123/rawlab:master

Get

Without Authorization

GET /username/repo@branch/path/to/file.ext HTTP/1.1

With Token in Header

GET /username/repo@branch/path/to/file.ext HTTP/1.1

Authorization: Bearer glpat-***************

With Token in URL

GET /username/repo@branch/path/to/file.ext?token=glpat-*************** HTTP/1.1

Why

  • to serve deno packages
  • to serve simple static web sites

Reminds

  • this will serve HTML files as text/html, be sure to trust your users!

About

Serves raw files from gitlab, with correct MIME types.


Languages

Language:Go 91.5%Language:Dockerfile 8.5%