A set of utilities to build API gateway.
Project description
Blackgate is an API gateway application. It’s stateless and extendable.
Install via pip
Run:
$ pip install blackgate
Or:
$ git clone git@github.com:soasme/blackgate.git $ cd blackgate $ python setup.py install
Install via docker
Run:
$ docker pull soasme/blackgate
Example
Configure Upstream
A minimal Blackgate config looks something like this:
--- proxies: - name: github upstream_url: 'https://api.github.com' request_path_regex: /github/(.*) request_path_sub: /\1
Just save it as blackgate.yml.
Run Application
Run application:
$ blackgate -c ./blackgate.yml start
Or via docker:
$ docker run -it --rm --name blackgate \ -p 9654:9654 \ -v blackgate.yml:/etc/blackgate.yml blackgate:v0.2.3
Test Blackgate
Using curl to test functionality:
$ curl http://127.0.0.1:9654/github/repos/soasme/blackgate {"id":59739087,"name":"blackgate","full_name":"soasme/blackgate", ...
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
blackgate-0.2.5.tar.gz
(7.9 kB
view hashes)
Built Distribution
Close
Hashes for blackgate-0.2.5-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3a393a34279d47fa0a87646bc441ae21238567f4cb896d6c9a398e553bbddd21 |
|
MD5 | 6313f9b9a905470eec57dd28e0da5e6d |
|
BLAKE2b-256 | 31a3737b76cc0039ecc9d1860b1fa29034be9b254cb4e9a1fe340ea55d04979d |