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.

Requirement

  • Python >= 3.7

Run

  • Local mode

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

    git clone https://github.com/craftslab/metalmetrics-py.git
    
    cd metalmetrics-py
    docker build --no-cache -f Dockerfile -t craftslab/metalmetrics-py:latest .
    docker run -it -p 9090:9090 craftslab/metalmetrics-py: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:
  bare:
    - cpu
    - disk
    - io
    - ip
    - kernel
    - mac
    - network
    - os
    - ram
    - system
  container:
  kubernetes:

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-4.3.1.tar.gz (15.7 kB view details)

Uploaded Source

Built Distribution

metalmetrics-4.3.1-py2.py3-none-any.whl (19.8 kB view details)

Uploaded Python 2 Python 3

File details

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

File metadata

  • Download URL: metalmetrics-4.3.1.tar.gz
  • Upload date:
  • Size: 15.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.1.2 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.6.9

File hashes

Hashes for metalmetrics-4.3.1.tar.gz
Algorithm Hash digest
SHA256 ff932eaa33dd7a1c76bff516eaf182c485bde2b94259479c7069c2768f8f7b51
MD5 b9b9cf47b32aba97c96b74ca429628e3
BLAKE2b-256 6b6fbf6763b2d3c37c772ed5c146de0d45c75d6edfdf006c3714ebbb3a029356

See more details on using hashes here.

File details

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

File metadata

  • Download URL: metalmetrics-4.3.1-py2.py3-none-any.whl
  • Upload date:
  • Size: 19.8 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.6.1 requests/2.25.1 setuptools/51.1.2 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.6.9

File hashes

Hashes for metalmetrics-4.3.1-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 38bafd1c53b6477422fb87119578f530f8094e9cd55ed6226f4d49e8531832fa
MD5 6ec3130dee40614efbff9ac3c1ae8485
BLAKE2b-256 779e81bb5fd3b9eaa7eeaa4e24c4fa94e346d7f8cc39614896408cb8a431ddab

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