Public Repository

Last pushed: 3 months ago
Short Description
This image collects it's CPU stats, Memory usage and Network stats and transmits every 15s.
Full Description

Introduction

This image is used for collecting CPU statistics, Memory Usage and Network statistics of itself.

Usage

  1. Create a folder: mkdir {folder_name}
  2. First, create a DockerFile:

    FROM perplexedgamer/stats_collector_2
    ENTRYPOINT ["python3", "/send_data.py"]
    CMD []

  3. docker build -t stats_collector_complete .
  4. sudo docker run stats_collector_complete {Destination_IP} {Destination_Port} &
    Example: sudo docker run stats_collector_complete 10.2.1.16 6640 &

Output

{ "TIMESTAMP": 17-05-26 23:59:32},{ "CPU": 1.12582%},{ "Memory": { "Used": 157M },{ "Available": 1.7G/2.0G } },{ "Network": { "Received_Bytes": 690 },{ "Transmitted_Bytes": 1254 } }

Docker Pull Command
Owner
perplexedgamer

Comments (0)