An OVH Logs Data Platform python client. Logs Data Platform is a log management platform based on OpenSearch.
Go to file
Freezed 75824ff5ac Add a basic OpenSearch client
1st command: list the stream mapping
2022-09-24 20:14:32 +02:00
.gitignore Add a basic OpenSearch client 2022-09-24 20:14:32 +02:00
LICENSE.md 📝 Define project base 2022-09-24 17:05:34 +02:00
Makefile Add a basic OpenSearch client 2022-09-24 20:14:32 +02:00
README.md Add a basic OpenSearch client 2022-09-24 20:14:32 +02:00
client.sample.py Add a basic OpenSearch client 2022-09-24 20:14:32 +02:00
main.py Add a basic OpenSearch client 2022-09-24 20:14:32 +02:00
pyproject.toml Add a basic OpenSearch client 2022-09-24 20:14:32 +02:00
requirements-dev.txt Add a basic OpenSearch client 2022-09-24 20:14:32 +02:00
requirements.txt Add a basic OpenSearch client 2022-09-24 20:14:32 +02:00

README.md

LDPy

🚧 work in progress 🚧

Take a look on other branches if you are curious…


An OVH Log Data Platform python client.

Log Data Platform is a log management platform based on opensearch.

💡 Idea

  1. Access LDP stream
  2. Query the logs
  3. Trigger actions

🚀 Use quick-start

Get the source & edit settings:

git clone git@gitlab.com:forga/tool/ovh/ldpy.git && cd ldpy
cp client.sample.py client.py
${EDITOR} client.py

Set up environment & run help:

mkdir ~/.venvs && python3 -m venv ~/.venvs/ldpy
source ~/.venvs/ldpy/bin/activate
pip install -r requirements.txt
python main.py -h
  • Get stream mapping: python main.py --mapping

🚧 Devel quick-start

  • Built with Python 3.8
  • Code linting with flake8, pylint, black & pydocstyle.
  • Install development tools:
    • pip install -r requirements-dev.txt
  • A Makefile with tools: run make help to have a look
  • Use the pre-commit git hook
    • echo "make --no-print-directory lint" > .git/hooks/pre-commit
    • chmod u+x .git/hooks/pre-commit

📌 Dependences

Details in requirements.txt & requirements-dev.txt