我在我的ruby on rails应用程序上使用了门卫来实现OAuth功能。突然,门卫变得无法在生产模式下为某些门卫::应用程序(我有三个门卫::应用程序设置)创建令牌而无需在生产日志文件中写入,但昨天它正常工作。
每次在POST" / oauth / token"门卫为此门卫::应用程序返回500页,但为另一门门票返回201。
当我在数据库中重新创建Doorkeeper :: Application配置而不更改参数时,门卫开始使用这条新记录正常工作。
我正在使用带门卫v 0.6.7的postgres。
这是我的gemfile:
source 'https://rubygems.org'
def darwin_only(require_as)
RUBY_PLATFORM.include?('darwin') && require_as
end
def linux_only(require_as)
RUBY_PLATFORM.include?('linux') && require_as
end
gem 'rails', '3.2.16'
gem 'jquery-rails'
gem 'pg'
gem 'slim-rails'
gem 'inherited_resources'
gem 'simple_form'
gem 'twitter-bootstrap-rails'
gem 'airbrake', '3.1.2'
gem 'devise'
gem 'httparty'
gem 'ledermann-rails-settings', :require => 'rails-settings'
gem 'carrierwave', git: 'git://github.com/jnicklas/carrierwave.git', ref: '809e86b697'
gem 'mini_magick'
gem 'ruby-progressbar'
gem 'doorkeeper', '~> 0.6.7'
gem 'jsonify-rails'
gem 'less-rails'
gem 'therubyracer', '0.12.1'
gem 'cancan'
gem 'push-core', git: 'git://github.com/tompesman/push-core.git', ref: '980ddc107f'
gem 'push-apns'
gem 'push-gcm'
gem 'delayed_job_active_record'
gem 'daemons'
gem 'recaptcha', require: 'recaptcha/rails'
gem 'validates_timeliness'
gem 'paper_trail'
gem 'oj'
gem 'kaminari'
gem 'newrelic_rpm'
gem 'russian'
gem 'nested_form', '~> 0.3.2'
gem 'select2-rails'
gem 'jquery-ui-rails'
gem 'bourbon'
gem 'axlsx_rails'
gem 'sanitize'
gem 'gilenson'
gem 'ace-rails-ap'
gem 'activerecord-postgres-hstore'
gem 'geocoder'
gem 'rest-client'
gem 'figaro'
gem 'rails-erd'
gem 'acts_as_singleton'
gem 'carrierwave-processing'
group :development do
gem 'thin'
gem 'capistrano'
gem 'capistrano-ext'
gem 'rvm-capistrano'
gem 'yard'
gem 'quiet_assets'
gem 'pry-rails'
gem 'pry-plus'
gem 'ZenTest', '4.9.5'
end
# Gems used only for assets and not required
# in production environments by default.
group :assets do
gem 'sass-rails', '~> 3.2.3'
gem 'coffee-rails', '~> 3.2.1'
gem 'uglifier', '>= 1.0.3'
gem 'jquery-datatables-rails', git: 'git://github.com/rweng/jquery-datatables-rails.git'
end
group :test, :development do
gem 'rspec-rails', '~> 2.0'
gem 'spork-rails'
# Guard
gem 'guard-rspec'
gem 'guard-spork'
# File changes
gem 'rb-fsevent', require: darwin_only('rb-fsevent')
gem 'rb-inotify', require: linux_only('rb-inotify')
# Notifications
gem 'terminal-notifier-guard', require: darwin_only('terminal-notifier-guard')
end
group :test do
gem 'factory_girl_rails'
gem 'shoulda-matchers'
gem 'autotest-rails'
gem 'ffaker'
gem 'webmock'
gem 'vcr'
gem 'capybara'
gem 'json_spec'
gem 'simplecov', require: false
gem 'simplecov-sublime-ruby-coverage', require: false
gem 'test_after_commit'
end
门卫有什么问题?