Skip to content

Latest commit

 

History

History
98 lines (72 loc) · 2.55 KB

Readme.md

File metadata and controls

98 lines (72 loc) · 2.55 KB

Giftoppr

Build Status

Getting started

You'll first need to grab a Dropbox API key from here: https://www.dropbox.com/developers.

When asked (full dropbox, or single folder only) choose single folder.

Set these env variables

DROPBOX_KEY=""
DROPBOX_SECRET=""

Then:

brew install postgresql imagemagick
createuser -sPE postgres # Creates the postgres user we use in database.yml

git clone [email protected]:desktoppr/giftoppr.git
cd giftoppr
bundle
rake db:schema:load
rake db:seed # Loads in gifs from ~/Dropbox/Apps/Giftoppr
rails server

Heroku

Ensure environment variables are available during deploys.

heroku labs:enable user-env-compile

Increase maximum database connections to 20

heroku config -s | awk '/^DATABASE_URL=/{print $0 "?pool=20"}' | xargs heroku config:add

You'll need these environment variables for asset_sync and S3

Environment Variables

DROPBOX_KEY=""
DROPBOX_SECRET=""
AWS_ACCESS_KEY_ID=""
AWS_SECRET_ACCESS_KEY=""
FOG_DIRECTORY=""
FOG_HOST=""
FOG_PROVIDER=""
ASSET_SYNC_GZIP_COMPRESSION=true
SECRET_TOKEN=""

CORS and S3

If you're hosting the gifs on S3, you'll need to edit its CORS configuration so it allows XHR requests

<?xml version="1.0" encoding="UTF-8"?>
<CORSConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
    <CORSRule>
        <AllowedOrigin>*</AllowedOrigin>
        <AllowedMethod>GET</AllowedMethod>
        <AllowedMethod>POST</AllowedMethod>
        <AllowedMethod>PUT</AllowedMethod>
        <AllowedHeader>*</AllowedHeader>
    </CORSRule>
</CORSConfiguration>

Contributers

Here are the amazing people that have contributed to Giftoppr. Thank you so much :)

Contributing

  1. Fork this repository
  2. Create your feature branch for each new feature (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push the branch to github (git push origin my-new-feature)
  5. Create new Pull Request

Looking for ideas? There may be some unassigned feature requests here