discourse-subscriptions/plugin.rb

21 lines
650 B
Ruby
Raw Normal View History

# name: choice-plugin
# about: Integrating Discourse with Stripe
2017-02-12 21:55:00 -05:00
# version: 0.3.2
# authors: Rimian Perkins
2017-02-12 21:55:00 -05:00
# url: https://github.com/choiceaustralia/choice-discourse
2017-01-30 21:28:41 -05:00
gem 'stripe', '1.58.0'
Rails.configuration.stripe = {
:publishable_key => ENV['STRIPE_PUBLISHABLE_KEY'] || Rails.application.config_for(:stripe)['publishable_key'],
:secret_key => ENV['STRIPE_SECRET_KEY'] || Rails.application.config_for(:stripe)['secret_key']
}
Stripe.api_key = Rails.configuration.stripe[:secret_key]
load File.expand_path('../lib/choice-discourse/engine.rb', __FILE__)
2017-01-30 21:28:41 -05:00
2017-02-06 21:56:22 -05:00
Discourse::Application.routes.prepend do
2017-02-09 23:10:47 -05:00
mount ::Choice::Engine, at: '/'
2017-01-30 21:28:41 -05:00
end