Giter Club home page Giter Club logo

monito's Introduction

Monito

It monitors the servers on a network using a config file and reports the users that are currently logged in it.

What is this repository for?

This repo is for Monito related development and issues. This app has not been tested on windows os.

Pre-requisites
- `pip` or `easy_install`
- Create a shared secret key for your machines in order to allow anonymous ssh login to monito.
Dependencies
* python3
* linux os
How to setup the app
* Clone the project
* Download virtualenvwrapper
    - `pip install virtualenvwrapper`
* Create new virtual environment
    - `mkvirtualenv monito`
* Shift to the environment
    - `source ~/.virtualenvs/monito/bin/activate`
* Install dependencies
	- `pip install -r dev-requirements.txt`
* Give execute permissions to the script (fetch_machines.sh)
	- `chmod +x ./monito.sh`
* Create a csv file (without headers) with the following format
    - hostname,owner name,username-to-use-to-login
Run the app
`python app.py`
Run the script for getting the live users
`./monito.sh -f /path/to/machinefile -k /path/to/ssh-key/file [-m <false/true>]`
Note: Running the above script with true will remove the owners and current users from the database.
Technical diagram

Misc
* Open `http://localhost:5000` for viewing the dashboard.
* Use `-h` for help menu

monito's People

Contributors

elmirbekic avatar hraga avatar ramanmangla avatar raul1991 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

monito's Issues

Fix issue with ssh command

There were multiple issues with the ssh command

  1. We cannot find if machine is down
  2. The machine file is not being iterated properly (just the first line is being parsed)

Show owner name in owner column and disable Action

Hi,

When i assign a machine to me from "free machine" tab it delete entry it from this tab, instead to delete just show owner name of this machine and disable "assign to me" button. This is because everyone knows who is using this machine.

Use snackbars for information display

Bootstrap snackbars can be integrated for messages. Create a common helper method that can be invoked from any js file for showing the message.

signature can be something like

timeout, message, type (danger,warn,info)

Add details in the README about testing the whole setup

Before we get testcases in place, there should be a section describing the steps to setup the e2e thing in Monito.

Example section

Testing

  • Run the script and the python server
  • Since the ping script updates the machine mapping with the users on the machine, you need to do this manually to trigger trespassing emails.
  • For allocation emails, you can click assign me button in the gui.

For email setup

  • Create .env file in the root of the repo with the following keys
  • USE_GMAIL=true
  • GMAIL_CREDS="base64-of-your-gmailid:password"
  • Also, turn on insecure apps in your gmail account so you can use it to send emails - here is the link https://myaccount.google.com/lesssecureapps

Add as much information as you can add.

Create a test environment

Setup a script that mocks the active users, owners at the back and see if that gets reflected at the front end.

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.