Development

Tiny Memorial - Built with Bootstrap

At Sakura Media, my co-worker and I pumped out a site called Tiny Memorial, a website for creating online memorials for pets or people. We built the project relatively quickly. We started work a Thursday afternoon and launched the product on the following Wednesday afternoon.

tiny memorial screen shot

The application was fairly simple to design because there are other online sites out there. The difference between the other sites and Tiny Memorial is that this site was “bootstrapped” by using a panoply of technologies and we have some social networking features that the other guys don’t.

Django 1.4 — Bleeding-edge Django tech. We were working on a RC candidate version and 1.4 became stable a few days after we launched.

Django socialauth — Allows visitors to login/join with Twitter or Facebook.

Twitter Bootstrap 2 — I really like working with Bootstrap. The engineer did an amazing job of making making the CSS really flexible. I aspire to achieve this level of CSS modularity/reusability. Visually, Bootstrap out-of-the-box is also great. All the UI elements and buttons are just there and I barely messed with them at all. In fact the ugly greenish yellow gradient for the header is all my choosing.

Compass — Ruby tool that compiles SASS and has a ton of ways to make life easier including cross-browser CSS3. I use Compass so much I haven’t used a -webkit prefix in months.

Facebook integration — When Facebook users create a new memorial we push the content onto their timeline. Fun stuff.

Python Facebook API open graph client

Since Facebook changed everything over to Open Graph they deprecated the pyfacebook library. This stack exchange thread suggests Facepy. Everybody else suggests using the Javascript API but I really just wanted something easy on the backend to execute a few curl requests per user action on the back end in my Django app. I haven’t used this library yet but we’ll see where it goes.

Facepy – Facebook API wrapper in python

Amazon S3 Website CNAME

While trying to create an S3-hosted static website I was trying to configure my domain to point to the S3 with a CNAME record on my DNS records for the domain.

The Amazon documentation mistakenly tells you to setup your CNAME to point to something like this:

#this is wrong!
 
my.domain.com CNAME my.domain.com.s3.amazonaws.com.
 
http://my.domain.com/index.html # will work
 
http://my.domain.com/ # will not work

This configuration will not work if you want directories to serve index.html by default. You may notice that if you type the complete URL you will get an S3 “Access Denied” message.

For your bucket, go to: Properties->Website
 
Endpoint: http://my.domain.com.s3-website-us-east-1.amazonaws.com/
You need: s3-website-us-east-1.amazonaws.com

Now you can configure your DNS settings.

# the proper configuration
 
my.domain.com CNAME s3-website-us-east-1.amazonaws.com.
 
http://my.domain.com/index.html # will work
 
http://my.domain.com/ # will work
Syndicate content