Gnip Classic
Gnip Classic
Here’s the migration snippet
class AddResultsTable < ActiveRecord::Migration
def self.up
create_partitioned_table :results do |t|
The below creates a results table partitioned by day. The example migration defaults to 4 days back and 4 days forward. We then have a few scripts to manage our partitioned tables.
Here’s the rails source
Here are the links to the software detailed in the script.
As before, the first part of the script removes pre-configured ruby packages and installs ruby and rubygems from scratch and the second part of the script installs nginx with ssl support and then sets up an example monk application.
Here is the full example
Here are the links to the software detailed in the script.
The first part of the script removes pre-configured ruby packages and installs ruby and rubygems from scratch.
The second part of the script installs nginx with ssl support and then sets up an example rails application.
Here is the full example
the #golf swing…unfortunately how I didn’t spend my xmas break
Below is an example of using Ruby and xmpp4r to check ejabberd’s status from within nagios
You’ll need to define the below nagios command within you nagios config file and then include the below ruby.
define command {
command_name check_xmpp
command_line ruby /opt/nagios/plugins/check_xmpp.rb --hostname $HOSTADDRESS$ --jid username@domain.com --password password
}
Here is the ruby example