I'm trying to have my website on both http and https using the request 
object as in the 

documentation:
http://api.rubyonrails.org/classes/ActionView/Helpers/AssetTagHelper.html

I've tried many configurations and many combinations, right now this is 
what I have in my environment/staging.rbconfig.action_controller.asset_host 
= Proc.new { |source, request=nil| if request && request.ssl? 
"https://staging.foobar.it"; else "http://assets#{ ( source.length % 4 ) + 1 
}.staging.foobar.it" end }


with this solution it appears like the request object is always set at nil.

I'm using Ruby 1.9.3 and rails 3.2.12, with nginx as reverse proxy and 
unicorn as app server, and precompiling my assets

Has someone been able to configure this and have the https website link to 
the right https asset server? What am I doing wrong?

TIA,
  ngw

-- 
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to rubyonrails-talk+unsubscr...@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msg/rubyonrails-talk/-/zZT2Qss6uqYJ.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to