This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var util = require('util'), | |
colors = require('colors'), | |
http = require('http'), | |
httpProxy = require('http-proxy'); | |
// | |
// Http Server with proxyRequest Handler and Latency | |
// | |
var proxy = new httpProxy.RoutingProxy(); | |
http.createServer(function (req, res) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def publish_activity! | |
activity = current_user.publish_activity(:send_karma, :object => karma, :target => receiver, :receivers => [receiver, current_user]) | |
activity.organization = current_organization | |
activity.save | |
activity.notify! | |
activity | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#removed a bunch of routes that aren't relevant | |
require 'rubygems' | |
require 'bundler' | |
require 'sinatra' | |
require 'haml' | |
require 'bson' | |
require 'models/user' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- url: /check | |
script: stashboard.py | |
secure: optional |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cron: | |
- description: periodic server checks | |
url: /check | |
schedule: every 30 minutes |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import urllib | |
import urllib2 | |
import socket | |
from google.appengine.api import urlfetch | |
from google.appengine.api.urlfetch import DownloadError | |
from google.appengine.ext import db | |
from models import Status, Service, Event | |
from datetime import datetime, timedelta, date |
NewerOlder