Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/1ambda/aram
https://github.com/1ambda/aram
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/1ambda/aram
- Owner: 1ambda
- Created: 2014-05-12T10:05:50.000Z (over 10 years ago)
- Default Branch: master
- Last Pushed: 2014-11-02T14:21:38.000Z (about 10 years ago)
- Last Synced: 2024-04-14T18:15:43.289Z (9 months ago)
- Language: JavaScript
- Size: 465 KB
- Stars: 0
- Watchers: 5
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# ARAM
Action Runner and Monitor
### 1. Guide**ARAM** consists of two parts. **Runner** and **Monitor**
#### \# Runner
**Runner** captures websites and checks whether services are availale by finding DOM unless **Runner** executes **actions**
**action** is a node.js script registered in **/runner/util/requirements.js** and exists in **/runner/actions/**
Every **action** must exports a function takes at least 1 argument.
The first argument is `done` callback which is should be called in **action** unless runner will be stop.
```javascript
// /aram/runner/actions/sample_action.jsmodule.exports = function(done, siteName) {
var exec = require('child_process').exec;
exec("node /home/auth/restart.js", function(err, stdout, stderr) {
if (err) {
console.log('err : ' + err);
}console.log('\n\tAction Result : \n\n' + stdout + '\n');
console.log((new Date()).toLocaleString() +
': Done action for service [' + siteName + ']');
done();
});
};
```
```javascript
// /aram/runner/config/requirements.js
// action is optionalmodule.exports = {
"context": [
{ "siteName" : 'accounts',
"url" : "https://accounts.service.com/public",
"tagToTest" : '#info-welcometex',
"action": 'knowlauth_restart.js' },
{ "siteName" : 'story',
"url" : "https://site.service.com",
"tagToTest" : '#welcome' }
]
};```
#### \# Monitor**Monitor** is web-service which provides other website's status using charts and images recorded by **Runner**.
### 2. Installation Guide```
$ sudo npm install -g phantomjs
$ sudo npm install -g casperjs
$ sudo npm install -g supervisor$ # git clone move to aram directory
$ git clone http://github.com/ansterd/aram
$ cd aram/aram $ npm install
/aram $ bower install
/aram $ npm start
/aram $ cd runner
/aram/runner $ npm start
```
### 3. Development Guide```
npm install -g phantomjs
npm install -g casperjs
npm install -g mocha
npm install -g grunt-cli
npm install -g less
npm install -g supervisor
```
### 4. Todo- Monitor diR structure
- action : nodemailer
- grunt build script [Use this](https://github.com/sindresorhus/grunt-shell)
- Grunt minify, uglify script and css
- less, grunt-contrib-less
- Logging with winston
- passport
- MongoDB virtual
- csurf