Skip to main content

Metal Metrics

Project description

metalmetrics

Actions Status Docker License PyPI Tag

Introduction

metalmetrics is a worker of metalflow written in Python.

Prerequisites

  • Python >= 3.7

Run

  • Local mode
git clone https://github.com/craftslab/metalmetrics.git

cd metalmetrics
pip install -Ur requirements.txt
python metrics.py --config-file="config.yml" --inxi-file="inxi" --output-file="output.json"
  • Service mode
git clone https://github.com/craftslab/metalmetrics.git

cd metalmetrics
pip install -Ur requirements.txt
python metrics.py --config-file="config.yml" --inxi-file="inxi" --listen-url="127.0.0.1:9090"

Docker

  • Local mode
git clone https://github.com/craftslab/metalmetrics.git

cd metalmetrics
docker build --no-cache -f Dockerfile -t craftslab/metalmetrics:latest .
docker run -it -v /tmp:/tmp craftslab/metalmetrics:latest ./metalmetrics --config-file="config.yml" --output-file="/tmp/output.json"
  • Service mode
git clone https://github.com/craftslab/metalmetrics.git

cd metalmetrics
docker build --no-cache -f Dockerfile -t craftslab/metalmetrics:latest .
docker run -it -p 9090:9090 craftslab/metalmetrics:latest ./metalmetrics --config-file="config.yml" --listen-url="127.0.0.1:9090"

Usage

usage: metrics.py [-h] --config-file CONFIG_FILE [--inxi-file INXI_FILE]
                  [--listen-url LISTEN_URL | --output-file OUTPUT_FILE] [-v]

Metal Metrics

optional arguments:
  -h, --help            show this help message and exit
  --config-file CONFIG_FILE
                        config file (.yml)
  --inxi-file INXI_FILE
                        inxi file (/path/to/inxi)
  --listen-url LISTEN_URL
                        listen url (host:port)
  --output-file OUTPUT_FILE
                        output file (.json|.txt|.xlsx)
  -v, --version         show program's version number and exit

Settings

metalmetrics parameters can be set in the directory config.

An example of configuration in config.yml:

apiVersion: v1
kind: worker
metadata:
  name: metalmetrics
spec:
  metrics:
    - cpu
    - disk
    - io
    - ip
    - kernel
    - mac
    - network
    - os
    - ram
    - system
    - users

Design

design

License

Project License can be found here.

Reference

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

metalmetrics-7.1.0.tar.gz (15.4 kB view details)

Uploaded Source

Built Distribution

metalmetrics-7.1.0-py2.py3-none-any.whl (19.4 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file metalmetrics-7.1.0.tar.gz.

File metadata

  • Download URL: metalmetrics-7.1.0.tar.gz
  • Upload date:
  • Size: 15.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.6.9

File hashes

Hashes for metalmetrics-7.1.0.tar.gz
Algorithm Hash digest
SHA256 d7edd9719cfbeb027eda079469f43340e7eb7dedd1b8cd36bade67218694d4e3
MD5 4aa4876dd940046c1f518ed539074f08
BLAKE2b-256 9b5c34fe25cca952a408a9aac22ab16b4746ed02aac4d30ee1ab4631fc822cbb

See more details on using hashes here.

File details

Details for the file metalmetrics-7.1.0-py2.py3-none-any.whl.

File metadata

  • Download URL: metalmetrics-7.1.0-py2.py3-none-any.whl
  • Upload date:
  • Size: 19.4 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.2 CPython/3.6.9

File hashes

Hashes for metalmetrics-7.1.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 71d891c7cb93226e9abaa1c5a925a7e146c91dc89d156013a56bbf3809d23e7e
MD5 07f15ab7c6b714b48d6bb49c32930dfc
BLAKE2b-256 d0e55e91357ae339cfde48fbc938c4e4b55a6a744febfe074ed3079d32a242ee

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page