Git Product home page Git Product logo

monitorflowmodule's Introduction

MonitorFlow Module

Description

This module is used by the application monitorflow to monitor multiple servers/computer. It need to be installed on each server.

Requirements

  • Rust (latest stable version recommended)
  • xcb
For Debian/Ubuntu-based distributions:
sudo apt-get update
sudo apt-get install libxcb1-dev
For Fedora, CentOS, RHEL:
sudo dnf install libxcb-devel  # Use dnf on Fedora
# or
sudo yum install libxcb-devel  # Use yum on CentOS/RHEL
For Arch:
sudo pacman -S libxcb

Installation

Step 1: Clone the Repository

git clone https://github.com/Kidoly/monitorflowmodule.git
cd monitorflowmodule

Step 2: Build the Program

cargo build --release

This command compiles your program in release mode. The compiled binary will be located at 'target/release/monitorflowmodule'.

Step 3: Configuration

You should modify the .env to your own PASSWORD and API_URL.

PASSWORD=YourPassword
API_URL=http://localhost:3000/api/api_receive
INTERVAL=600 # Time in seconds between each execution

Step 4: Running the Program

To run the program, navigate to the directory and execute it:

cargo run

Setting Up Automatic Launch

Linux (Using systemd)

  1. Create a systemd service file for your program at '/etc/systemd/system/monitorflowmodule.service'. Replace monitorflowmodule and /path/to/ with the actual path to your program:
[Unit]
Description=MonitorFlow Module Service

[Service]
ExecStart=/path/to/monitorflowmodule
WorkingDirectory=/path/to/your/program/directory
EnvironmentFile=/path/to/your/program/directory/.env
Restart=always

[Install]
WantedBy=multi-user.target

For example if you put the program in your home it should look like this:

[Unit]
Description=MonitorFlow Module Service

[Service]
ExecStart=/home/kidoly/monitorflowmodule/target/release/monitorflowmodule
WorkingDirectory=/home/kidoly/monitorflowmodule
EnvironmentFile=/home/kidoly/monitorflowmodule/.env
Restart=always

[Install]
WantedBy=multi-user.target
  1. Enable and start the service:
sudo systemctl enable monitorflowmodule.service
sudo systemctl start monitorflowmodule.service

This will set monitorflowmodule to start automatically at boot.

monitorflowmodule's People

Contributors

kidoly avatar dependabot[bot] avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.