我正在遵循https://github.com/nbudin/devise_cas_authenticable上的说明。但是,使用它before_filter :authenticate_user!
仍然会使应用程序尝试使用设计的数据库身份验证策略进行身份验证。下面是设计配置文件:
Devise.setup do |config|
require 'devise/orm/active_record'
config.cas_base_url = 'https://cas.uwaterloo.ca/cas'
# If true, uses the password salt as remember token. This should be turned
# to false if you are not using database authenticatable.
config.use_salt_as_remember_token = true
# ==> Configuration for :token_authenticatable
# Defines name of the authentication token params key
config.token_authentication_key = :auth_token
# The default HTTP method used to sign out a resource. Default is :delete.
config.sign_out_via = :delete
end
谢谢!