Topic: How to us FOG
I'm a newbie.
I would like to use FOG in connection with Amazon S3.
The instruction say to use this for the connection:
--------------------------
require 'rubygems'
require 'fog'
# create a connection
connection = Fog::Storage.new({
:provider => 'AWS',
:aws_secret_access_key => YOUR_SECRET_ACCESS_KEY,
:aws_access_key_id => YOUR_SECRET_ACCESS_KEY_ID
-----------------------
Where do you put this? In the controller?
does it need a def tag?
Thanks,
Reddirt
Last edited by reddirt (2012-02-06 18:53:11)