Wazuh Api Rest
Project description
Wazuh Api Rest
This application expose an api rest for handling User and User's tasks.
Run Local Test Server
This application use docker and docker compose to run a local server. So first make sure you have this two installed in your pc.
Steps to run the local server:
$ docker-compose up
After application start you can access the OpenApi documentation at http:://localhost:5002/docs
Run Local Development Server
You need to create a virtualenv and install the dependencies with pip:
$ python3 -m venv $PWD/myvenv
$ source myvenv/bin/activate
$ pip install -r requirements.txt
For test your development you can run the application in debug mode like this:
$ python src/setups/runapp.py --debug
After application start you can access the OpenApi documentation in http:://localhost:5002/docs
Run tests
In order to run the unit test suit, first you need to setup the PYTHONPATH envvar like this
$ export PYTHONPATH=$PWD/src
For run test do
$ python -m pytest test
Build for Distribution
If you need build a distribution package run the following command:
$python -m build
Then you will see a new folder named dist/
which contains the .tar.gz
and .whl
file for
distribution.
Deploy in Heroku
For deploy in Heroku you need first login to your account and then run the following commands:
- Run container login
$heroku container:login
Then create a new app, choose a name for your app, for example I will use your-app-name
$heroku create your-app-name
Now you need to push your container and link it to your app
$heroku container:push web -a your-app-name
Last step is release
$heroku container:release web -a your-app-name
Now you can access your app at your-app-name.herokuapp.com/docs
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
Built Distribution
File details
Details for the file wazuh-api-rest-0.0.1.tar.gz
.
File metadata
- Download URL: wazuh-api-rest-0.0.1.tar.gz
- Upload date:
- Size: 11.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.26.0 requests-toolbelt/0.9.1 urllib3/1.26.6 tqdm/4.62.3 importlib-metadata/4.10.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 657d5b39bac755314eb01de722edf72d3be57b9f5ed559163d0a84c6f0b9f878 |
|
MD5 | 2f4f44af1c7bee273e49da899a45fdd2 |
|
BLAKE2b-256 | 9335e874b422f1a989206b4e3fb29653f176a7352759f73f3d94d49f335bec41 |
File details
Details for the file wazuh_api_rest-0.0.1-py3-none-any.whl
.
File metadata
- Download URL: wazuh_api_rest-0.0.1-py3-none-any.whl
- Upload date:
- Size: 12.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.26.0 requests-toolbelt/0.9.1 urllib3/1.26.6 tqdm/4.62.3 importlib-metadata/4.10.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.9.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3d0a0a3e0a36b77f3a47b1701da16b9dba771488c718b54a6fc0df09c4f5fcde |
|
MD5 | 87fa25cf142754f4c3aa712908fc3db8 |
|
BLAKE2b-256 | 54d5a0f123c008fce4675fd136f96990fb7d29b05a1e5f91d1a644f3d1395aba |