Sha256: 14180b1dcaebc91e92e572a065069440f79cfc4c338e6937af7e6f61a213883c

Contents?: true

Size: 445 Bytes

Versions: 1

Compression:

Stored size: 445 Bytes

Contents

$:.push File.dirname(__FILE__) + '/../lib'

require 'rubygems'
require 'bundler'
Bundler.setup :default, :development, :example, ENV['RACK_ENV']

require 'sinatra'
require 'omniauth-persona'
require 'pry'

use Rack::Session::Cookie
use OmniAuth::Strategies::Persona

get '/' do
  "<a href='/auth/persona'>Auth with Persona</a>"
end

post '/auth/persona/callback' do
  content_type 'text/plain'
  request.env['omniauth.auth'].to_hash.inspect
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
omniauth-persona-0.0.1 examples/sinatra/application.rb