Added Installation section to README

This commit is contained in:
Ivan Golikov 2022-06-13 00:56:09 +03:00
parent 3d466c8e82
commit 2897e81a11

View file

@ -10,6 +10,47 @@ on a server will be IP address of the client that made request to the server.
Service is built with Python, FastAPI and is using Redis for data storage.
## Installation
### Requirements
- Python 3.10+
- Redis
- Python development libraries (optional, only needed for `hiredis` module installation)
### How to install
#### TL/DR
```
$ git clone git@git.ivnglkv.ru:ivnglkv/rectes.git
$ python3 -m venv venv
$ . ./venv/bin/activate
$ pip install ".[hiredis]"
```
---
Steps to install Rectes:
1. Clone repository
2. (optional) Create virtual environment
3. Install package
#### Optional `hiredis` module
Rectes server is using `aioredis` library for interaction with Redis. It's authors recommend using
it with `hiredis` module for performance and stability reasons
([source](https://github.com/aio-libs/aioredis-py#installation)).
Rectes offers `hiredis` as optional but recommended dependency too. Thus, the recommended way to install
Rectes will be with `[hiredis]` option. If you don't want to use `hiredis` for any reasons, install
package without options:
```
$ pip install .
```
## Contributing
Codestyle is enforced with Black, and additional checks are done with the help of pre-commit-hooks,