Sha256: 2d6119fc1555ec344ef5bf7fbcc998fc041f1d330050f4caa28c6f32ca00e9ce

Contents?: true

Size: 1.53 KB

Versions: 2

Compression:

Stored size: 1.53 KB

Contents

MultiAuth
=========

This engine provides basic signup/login functionalities for your Rails applications.

Install
=======

  $ sudo gem install okkez-multi_auth

or

  $ sudo gem install multi_auth

Setup
=====

RAILS_ROOT/config/environment.rb:

  config.gem "multi_auth"

or

  config.gem "okkez-multi_auth", :lib => "multi_auth"


  $ ruby script/generate open_id_authentication_tables create_open_id_authentication_tables

Create migrations for open_id_authentication.

  $ ruby script/generate multi_auth_migration create_multi_auth_tables

Create migrations for multi_auth.

  $ rake db:migrate

You must have a model 'User'. User model has any columns which you want to add.

Ex.

  class User < ActiveRecord::Base
    multi_auth
  end

You can use MultiAuthHelper, see below.

Ex.

  module ApplicationHelper
    include MultiAuthHelper
  end

You can use default style sheet and icons.

  $ ruby script/generate multi_auth_public_assets


Settings
========

You can config in RAILS_ROOT/config/initializers/*.rb

Ex.

  MultiAuth.setup do |s|
    s.application_name = 'Your app name'
    s.from_address = 'yourname@example.com'
    s.user_model = 'YourUserModel'
    s.session_times_out_in = 1.hour
  end

You can use OpenID::CustomFetcher to use OpenID provider which uses SSL.

Ex.

  OpenID.fetcher = OpenID::CustomFetcher.new
  OpenID.fetcher.ca_path = OpenSSL::X509::DEFAULT_CERT_PATH

Customize
=========

If you want to use custom views, you can create RAILS_ROOT/app/view/{activation_mailer,auth,credentials,signup}/*.


TODO
====

see TODO.ja

Version data entries

2 entries across 2 versions & 2 rubygems

Version Path
okkez-multi_auth-0.1.0 README
multi_auth-0.1.0 README