Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
G

gate

> 编程语言
Open source

"gate" for your private resources gate is a static file server and reverse proxy integrated with OAuth2 account authentication. With gate, …

184 stars0 likes0 views
WebsiteGitHub

About

"gate" for your private resources gate is a static file server and reverse proxy integrated with OAuth2 account authentication. With gate, …

"gate" for your private resources

gate is a static file server and reverse proxy integrated with OAuth2 account authentication.

With gate, you can safely serve your private resources based on whether or not request user is a member of your company's Google Apps or GitHub organizations.

Usage

  1. Download binary or go get
  2. rename config_sample.yml to config.yml
  3. edit config.yml to fit your environment
  4. run gate

Example config

…

Authentication Strategy

gate now supports Google Apps and GitHub to authenticate users.

Example config for Google

yaml
auth:
  info:
    service: google
    client_id: your client id
    client_secret: your client secret
    redirect_url: https://yourapp.example.com/oauth2callback

# restrict user request. (optional)
restrictions:
  - yourdomain.com    # domain of your Google App
  - [email protected] # specific email address

Example config for GitHub

Unlike the example of Google Apps above, if the service is GitHub, gate uses whether request user is a member of organization designated like below:

yaml
auth:
  info:
    service: github
    client_id: your client id
    client_secret: your client secret
    redirect_url: https://yourapp.example.com/oauth2callback

# restrict user request. (optional)
restrictions:
  - foo_organization
  - bar_organization

github:e support

GitHub Enterprise is also supported. To authenticate via github enterprise, add api endpoint information to config like following:

yaml
auth:
  info:
    service: github
    client_id: your client id
    client_secret: your client secret
    redirect_url: https://yourapp.example.com/oauth2callback
    endpoint: https://github.yourcompany.com
    api_endpoint: https://github.yourcompany.com/api

Name Based Virtual Host

An example of "Name Based Viatual Host" setting.

yaml
auth:
  session:
    # authentication key for cookie store
    key: secret123
    # domain of virtual hosts base host
    cookie_domain: gate.example.com

# proxy definitions
proxy:
  - path: /
    host: elasticsearch.gate.example.com
    dest: http://127.0.0.1:9200

  - path: /
    host: influxdb.gate.example.com
    dest: http://127.0.0.1:8086

License

MIT

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

Go

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 18, 2026
Category编程语言
PricingOpen source

> Related tools

T
TypeScript
JavaScript 的超集,为前端与全栈提供静态类型
P
Python
通用编程语言,广泛用于 Web、数据与 AI
G
Go
Google 推出的简洁高效系统语言