I've been struggling to specify custom callback_url for salesforce. Locally my application is running on http://test.lvh.me:3000/ (Please note custom subdomain test)
My code is:
# config/initializers/omniauth.rb
Rails.application.config.middleware.use OmniAuth::Builder do
provider :salesforce, 'consumer_key','consumer_secret', callback_path: 'http://localhost:3000/auth/salesforce/callback'
end
app/views/salesforces/show.haml
= link_to 'click here', "/auth/salesforce"
generated link contains redirect_uri parameter that looks like:
redirect_uri=http%3A%2F%2Ftest.lvh.me%3A3000http%3A%2F%2Flocalhost%3A3000%2Fauth%2Fsalesforce%2Fcallback
Basically it squeezes together my host test.lvh.me:3000/auth/salesforce/callback and localhost:3000/auth/salesforce/callback and puts it all into redirect_uri.
How can I get rid of test.lvh.me:3000/auth/salesforce/callback in the redirect_uri parameter?
Hi there, thanks for the gem.
I've been struggling to specify custom callback_url for salesforce. Locally my application is running on
http://test.lvh.me:3000/
(Please note custom subdomaintest
)My code is:
app/views/salesforces/show.haml
generated link contains redirect_uri parameter that looks like:
redirect_uri=http%3A%2F%2Ftest.lvh.me%3A3000http%3A%2F%2Flocalhost%3A3000%2Fauth%2Fsalesforce%2Fcallback
Basically it squeezes together my hosttest.lvh.me:3000/auth/salesforce/callback
andlocalhost:3000/auth/salesforce/callback
and puts it all into redirect_uri.How can I get rid of
test.lvh.me:3000/auth/salesforce/callback
in the redirect_uri parameter?Thanks