Sha256: 45abdce64292e18a8f884592baabb8ad78e91265f42023592b7ec0a2172c21a0
Contents?: true
Size: 1.2 KB
Versions: 2
Compression:
Stored size: 1.2 KB
Contents
= SalesKing OmniAuth Strategy If you are into omniAuth you can use this class to authenticate with SalesKing. Since every SK Account resides within its own subdomain, you need to set it before you want to use it. You can use this file as a starting point because you might want to change the subdomain detection. If you find it useful and fiddled around with it, please let us know so we can enhance it. == Install gem install sk_sdk If you are using bundler add to Gemfile gem "sk_sdk" # or directly require used class gem "sk_sdk", :require => "sk_sdk/ar_omni_auth/salesking" == Usage An initializers/omniauth.rb might look somethign like this: # if you copied the file into your lib/ require File.expand_path('../../../lib/sk_auth', __FILE__) # or from gem require "sk_sdk/omni_auth/salesking" begin sk = YAML.load_file(File.join(Rails.root, 'config', 'salesking.yml')) sk = sk[Rails.env] rescue puts "Error reading config/salesking.yml please create and review this file" end Rails.application.config.middleware.use OmniAuth::Builder do provider :salesking, sk['key'], sk['secret'], sk['url'] end Copyright (c) 2011 Georg Leciejewski, released under the MIT license
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
sk_sdk-0.0.7 | lib/sk_sdk/omni_auth/README.rdoc |
sk_sdk-0.0.6 | lib/sk_sdk/omni_auth/README.rdoc |