https://github.com/izdi/aiohttp-gateway
aiohttp REST by example
https://github.com/izdi/aiohttp-gateway
aiohttp docker docker-compose example pipenv python3 rest
Last synced: 3 months ago
JSON representation
aiohttp REST by example
- Host: GitHub
- URL: https://github.com/izdi/aiohttp-gateway
- Owner: izdi
- Created: 2018-05-23T18:21:00.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2018-05-23T19:28:35.000Z (about 8 years ago)
- Last Synced: 2026-01-13T08:49:17.042Z (5 months ago)
- Topics: aiohttp, docker, docker-compose, example, pipenv, python3, rest
- Language: Python
- Homepage:
- Size: 13.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# System requirements
* PostgreSQL 9.6.5+
* Python 3.6.5+
* Docker (optional)
# Pipenv
### Install https://github.com/pypa/pipenv#installation
#### Install deps
$ pipenv install
#### Activate
$ pipenv shell
#### Migrate
$ pipenv run migrate
#### Server
$ pipenv run service
# Dockerized environment
$ docker-compose -f docker/docker-compose-local.yml up
# Examples
Using https://httpie.org/
$ http 0.0.0.0:8080/restaurants
$ http POST 0.0.0.0:8080/restaurants name=Sadhu opens_at=2018-05-23T09:49:30Z closes_at=2018-06-23T09:49:30Z
$ http 0.0.0.0:8080/restaurant/1
$ http PUT 0.0.0.0:8080/restaurant/1 name='Sadhu Sundar'
$ http DELETE 0.0.0.0:8080/restaurants/1
# Tests
$ pipenv run tests