Skip to content

dam0/server-monitor

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 

Repository files navigation

Server Monitoring using Dropbox as a Database

Overview

Monitor the health of your servers and receive alerts when something goes wrong. This web application is built with the Opa technology and runs on top of a Dropbox-based database.

Demo

Main website and live demo at http://server-monitor.herokuapp.com/

Dropbox Storage

  • All your configured jobs and logs are saved on your personal Dropbox account. Nothing is stored on the application server.
  • If one of your severs goes down, a Dropbox popup will appear on your desktop.

The following code is a Dropbox database in Opa. Change the @dropbox annotation with @mongo and the app will run on top of MongoDB instead. It's that simple.

database monitor @dropbox {
    stringmap(log) /logs
    stringmap(job) /jobs
    /logs[_]/status = { ok } // Define the default "status" value
}

function add(name, url, freq){
	/monitor/jobs[name] <- (~{ url, freq })
}

Note: This application is a proof of concept, aim to learn the Opa Framework and to present a Dropbox-based database use case. The demo will stop monitoring your servers as soon as you close the page: fork the project and make you own production-ready version!

Compile

Download and install Opa, then compile the single file:

opa main.opa

Run

Create an app on Dropbox website and use the app keys to start the application:

./main.js --db-remote:monitor app-key:app-secret

Tutorial

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published