Polls AT&T API, gathers the results and displays on a dashboard.
http://www.ruby-lang.org/en/downloads/
See below various ways to install it.
# Debian / Ubuntu
sudo apt-get install libsqlite3-dev
# RedHat / Fedora
sudo yum install sqlite-devel
# MacPorts
sudo port install sqlite3
# HomeBrew
sudo brew install sqlite
On SQLite everything is saved in a small lightweight file. If you want to browse this file there's an utility software that works great: http://sourceforge.net/projects/sqlitebrowser/
$ gem install bundler
$ bundle install
There's 2 main components: the webapp and the poller script. In a terminal window execute the command below to start the webapp.
$ ruby config/runners/web_app.rb
You can hit the index on http://127.0.0.1:5985.
In another terminal window, start the poller. It will execute and sleep for 1 hour before next execution.
$ ruby config/runners/api_poller.rb
The poller will execute, gather the results, and save everything on a local SQLite database file.
You can also run the app as daemon. This is mainly used in our production server.
$ ruby config/runners/web_app_daemon.rb start
$ ruby config/runners/api_poller_daemon.rb start
As daemon you have easier options to start, stop or reload the processes.
Before start please be advised that the deployment process is pretty manual. You'll need ssh access to our Amazon instance, and also need to build the Ext app for production, making sure everything is on github.
$ ssh [email protected]
After connection stop the processes
$ sudo /etc/init.d/att_poller_runner stop
$ sudo /etc/init.d/att_webapp_runner stop
Go to the project directory
$ cd ~/ATT-Reporter
This directory is actually a git project. So get the new code
$ git reset --hard
$ git pull #will ask for your github auth
And after that, replace the development javascript by production JavaScript:
$ cp -rf public/build/Reporter/production/*.* public/
Restart processes
$ sudo /etc/init.d/att_poller_runner start
$ sudo /etc/init.d/att_webapp_runner start