Git Product home page Git Product logo

realtime-server-health-monitor's Introduction

Laravel Live Server Monitoring App

A sample Laravel app for monitoring the status of remote servers. This includes monitoring for the following:

  • Disk space
  • Memory
  • CPU
  • Apache
  • MySQL
  • Beanstalkd

You can read the full tutorial at: https://pusher.com/tutorials/server-health-monitor-laravel

Prerequisites

Getting Started

  1. Clone the repo:
git clone https://github.com/anchetaWern/realtime-server-health-monitor.git
  1. Create a new Laravel project:
composer create-project --prefer-dist laravel/laravel liveservermonitor
  1. Copy all the relevant files from the cloned repo over to your newly generate project. Note that only the files that were changed or added for the app is added in the repo. So don't replace entire folders in your project with the one's in the repo. Only copy over the relevant files.

  2. Install the backend dependencies:

composer install
  1. Install the frontend dependencies and compile the scripts:
npm install
npm run dev
  1. Update the .env file with your database credentials:
DB_CONNECTION=mysql
DB_HOST=localhost
DB_PORT=3306
DB_DATABASE=server_monitor
DB_USERNAME=YOUR_DB_USERNAME
DB_PASSWORD=YOUR_DB_PASSWORD

And Pusher credentials:

BROADCAST_DRIVER=pusher
CACHE_DRIVER=file
QUEUE_CONNECTION=sync

PUSHER_APP_ID=YOUR_PUSHER_APP_ID
PUSHER_APP_KEY=YOUR_PUSHER_APP_KEY
PUSHER_APP_SECRET=YOUR_PUSHER_APP_SECRET
PUSHER_APP_CLUSTER=YOUR_PUSHER_APP_CLUSTER
  1. Migrate the database:
php artisan migrate
  1. Add virtual host for your project (e.g. liveservermonitor.loc).

  2. Add a host to monitor:

php artisan server-monitor:add-host
  1. Run the checks:
php artisan server-monitor:run-checks
  1. Add project to cron:
* * * * * cd /path-to-your-project && php artisan schedule:run >> /dev/null 2>&1
  1. Monitor your servers.

Built With

Donation

If this project helped you reduce time to develop, please consider buying me a cup of coffee :)

Buy Me A Coffee

realtime-server-health-monitor's People

Contributors

anchetawern avatar

Watchers

James Cloos 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.