Showing posts from February, 2016

Extending a linux web dashboard

Adding pm2 status to linux-dash linux-dash is a light-weight, open-source web dashboard to monitor your linux machine or virtual machine. You can find this package on Github . The dashboard reports many different aspects of our linux installation via shell scripts (*.sh). This allows the dashboard to be light-weight, and work on most linux machines. The website displays running charts, and tables. The web site can be node, php, or go. For the node webserver, the only dependencies are express and websocket. Extending linux-dash You may have a few extra services or programs running on your linux installation that you would like to display on linux-dash . I use pm2 , a process manager. Adding a table to display the pm2 status information was very easy -- even if you are not familiar with client-side Angular directives or server-side Node.JS or server-side shell scripts. The naming convention and templating allows us to focus on the few components we need to build without st

Prototyping in MongoDB with the Aggregation Pipeline stage operator $sample

Prototyping in MongoDB with the Aggregation Pipeline stage operator $sample The World Map as a visual example In order to show how the random sampling works in the mongoDB query, this NodeJS Express website will show the world map and display random latitude/longitude points on the map. Each refresh of the page will produce new random points. Below the map, the docs will display. Once the website is up and working with data points, we will play with the query to see how the data points change in response. The demonstration video is available on YouTube . Setup steps for the website Setup This article assumes you have no mongoDB, no website, and no data. It does assume you have an account on Compose . Each step is broken out and explained. If there is a step you already have, such as the mongoDB with latitude/longitude data or a website that displays it, skip to the next. get website running, display map with no data setup the mongoDB+ ssl database get mock d