This file contains 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
#!/usr/bin/env ruby | |
# Pass in the name of the site you wich to create a cert for | |
domain_name = ARGV[0] | |
if domain_name == nil | |
puts "Y U No give me a domain name?" | |
else | |
system "openssl genrsa -out #{domain_name}.key 1024" | |
system "openssl req -new -key #{domain_name}.key -out #{domain_name}.csr -subj '/C=US/ST=NJ/L=Monroe/O=MyCompany/OU=IT/CN=#{domain_name}'" |
This file contains 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 update_sb_for_bad_cards(increment=500) | |
cmd = OrientDB::SQLCommand.new("select count(*) from card") | |
res = Oriented.graph.command(cmd).execute | |
count = res.to_a.first["count"] | |
loop_count = count/increment | |
start_id = 0 | |
(0..loop_count).each do |num| | |
end_id = start_id + increment |
This file contains 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 report_bad_accounts | |
no_bad = 0 | |
CSV.foreach('play_accounts.csv', headers: true) do |row| | |
acc = Account.where(email: row['email']).first | |
puts "Account not found for #{row['email']}" && next unless acc | |
unless acc.kyck_id.to_s == row['kyck_id'] | |
no_bad += 1 | |
puts "KYCK IDs don't match for #{row['email']}" | |
puts "Auth KYCK ID=#{acc.kyck_id.to_s} / Play KYCK ID=#{row['kyck_id']}" | |
end |
This file contains 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
gp1 = KyckPipeline.new(Oriented.graph) | |
gp2 = KyckPipeline.new(Oriented.graph) | |
gp.copy_split( | |
gp1._().out(UserData.relationship_label_for(:plays_for)).filter {|it| it["@class"] == "Roster"}.in(TeamData.relationship_label_for(:rosters)), | |
gp2._().out(UserData.relationship_label_for(:staff_for)).filter {|it| it["@class"] == "Team"} | |
).fair_merge | |
This file contains 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
if organization_params[:address1] | |
puts "We have location" | |
@org.locations << Location.build(organization_params) | |
end | |
@org.valid? if true == session.delete(:org_valid) | |
@org.extend(OrganizationRepresenter) | |
render(has_ajax: false) |
This file contains 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
How to setup Heroku Hostname SSL with GoDaddy SSL Certificate and Zerigo DNS | |
Heroku recently added an exciting new 'Hostname SSL' option. This option offers the broad compatibility of IP-based SSL, but at 1/5 the price ($20 / month at the time of this writing). | |
The following tutorial explains how to use Heroku's new 'Hostname SSL' option on your Heroku project. Before we begin, let's list what we're using here: | |
* Heroku Hostname SSL | |
* GoDaddy Standard SSL Certificate | |
* Zerigo DNS |
This file contains 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
How to setup Heroku Hostname SSL with GoDaddy SSL Certificate and Zerigo DNS | |
Heroku recently added an exciting new 'Hostname SSL' option. This option offers the broad compatibility of IP-based SSL, but at 1/5 the price ($20 / month at the time of this writing). | |
The following tutorial explains how to use Heroku's new 'Hostname SSL' option on your Heroku project. Before we begin, let's list what we're using here: | |
* Heroku Hostname SSL | |
* GoDaddy Standard SSL Certificate | |
* Zerigo DNS | |
Note: I am not using the Heroku Zerigo DNS add-on, instead I have a separate Zerigo account for my DNS needs. I do this because Zerigo offers 30 hosts on free direct accounts, versus only 10 hosts on the free Heroku add-on. |
This file contains 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
basemodel.0.ocl event.0.ocl organization.0.ocl rule.0.ocl team__rosters.0.ocl | |
BaseModel.kyck_id.sbt event.och Organization.name.sbt rule.och team__rosters.och | |
basemodel.och index.0.ocl organization.och sanctioningbody.0.ocl txlog.otx | |
card.0.ocl index.0.oda orids.0.ocl SanctioningBody.name.sbt UniquePlayer.sbt | |
card.och index.och orids.och sanctioningbody.och UniqueSanctions.sbt | |
competition.0.ocl index.odh orole.0.ocl sanctioningrequest.0.ocl UniqueStaff.sbt | |
competition.och internal.0.ocl ORole.name.sbt sanctioningrequest.och user.0.ocl | |
database.ocf internal.och orole.och sanctions.0.ocl User.email.sbt | |
default.0.ocl location.0.ocl oschedule.0.ocl sanctions.och user__locations.0.ocl | |
default.0.oda |
This file contains 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
[Server:server-one] 18:43:55,107 INFO [org.torquebox.core.runtime] (Thread-7 (HornetQ-client-global-threads-1006411657)) Setting up Bundler | |
[Server:server-one] 18:44:09,026 ERROR [stderr] (Thread-7 (HornetQ-client-global-threads-1006411657)) undefined method `loaders' for #<Java::OrgInfinispanConfigurationCache::Configuration:0x38d76588> | |
[Server:server-one] 18:44:09,027 ERROR [stderr] (Thread-7 (HornetQ-client-global-threads-1006411657)) /opt/torquebox/jruby/lib/ruby/gems/shared/gems/torquebox-cache-3.0.0-java/lib/torquebox/cache.rb:330:in `same_config?' | |
[Server:server-one] 18:44:09,028 ERROR [stderr] (Thread-7 (HornetQ-client-global-threads-1006411657)) /opt/torquebox/jruby/lib/ruby/gems/shared/gems/torquebox-cache-3.0.0-java/lib/torquebox/cache.rb:291:in `reconfigure' | |
[Server:server-one] 18:44:09,028 ERROR [stderr] (Thread-7 (HornetQ-client-global-threads-1006411657)) /opt/torquebox/jruby/lib/ruby/gems/shared/gems/torquebox-cache-3.0.0-java/lib/torquebox/cache.rb:273:in `cache' | |
[Server:server-one] 18:44:09 |
This file contains 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
/opt/torquebox/jruby/lib/ruby/gems/shared/gems/activerecord-3.2.12/lib/active_record/connection_adapters/abstract/connection_pool.rb:410:in `retrieve_connection'", | |
"/opt/torquebox/jruby/lib/ruby/gems/shared/gems/activerecord-3.2.12/lib/active_record/connection_adapters/abstract/connection_specification.rb:171:in `retrieve_connection'", | |
"/opt/torquebox/jruby/lib/ruby/gems/shared/gems/activerecord-3.2.12/lib/active_record/connection_adapters/abstract/connection_specification.rb:145:in `connection'", | |
"/opt/torquebox/jruby/lib/ruby/gems/shared/gems/activerecord-3.2.12/lib/active_record/model_schema.rb:228:in `columns'", | |
"/opt/torquebox/jruby/lib/ruby/gems/shared/gems/activerecord-3.2.12/lib/active_record/model_schema.rb:237:in `columns_hash'", | |
"/opt/torquebox/jruby/lib/ruby/gems/shared/gems/activerecord-3.2.12/lib/active_record/locking/optimistic.rb:129:in `locking_enabled?'", | |
"/opt/torquebox/jruby/lib/ruby/gems/shared/gems/activerecord-3.2.12/lib/active_record/relation.rb:170:in `exec_queries'", | |
"/opt/tor |