rails3 is a simple hack done in one hour of drone coding using the Amazon S3 Ruby API. The expected result was feel how would be use the new technology in a ruby on rails environment.
This application was done to help me understand how I can use Amazon S3 and I’m not responsible for any damage you can do to your computer, amazon account or environment. Use at your own risk!
1: At this time the application just work if a pre-created bucket name
was defined here. If you don’t have created a bucket before please check the
API documentation about how do that.
2: All uploaded files are automatically defined as public, so will be
accessible by any web browser, so don’t upload sensible data.
The application is pretty minimal, just a controller and a view. There’s no
database layer (so no model files) and it’s very easy to deploy.
1 – edit the config/environment.rb file, changing the last 3 lines:
AWS_ACCESS_KEY_ID = '00000000000001' # your AWS ACCESS KEY AWS_SECRET_ACCESS_KEY = 'D558U*EFHmfdoijnej78847499dfh98whud9' # your SECRET BUCKET = 'bucket-name' # a PREVIOUS CREATED bucket
2 – run the script/server command to start webrick
3 – launch your browser and access http://localhost:3000/
4 – there’s no step 4 :)
Published with Backpack. This page is subject to the terms of service.