Get the domain-redirect nginx config working.

Summary:
It was working fine for http but I needed to add certificate support
for https.

Test Plan:
I set this up on a new machine and did

   curl -D- http://54.162.86.23/'foo?bar' -H'Host: khanacademy.org'

and it said:

    HTTP/1.1 301 Moved Permanently
    Server: nginx/1.6.2
    Date: Tue, 07 Oct 2014 23:30:15 GMT
    Content-Type: text/html
    Content-Length: 184
    Connection: keep-alive
    Location: http://www.khanacademy.org/foo?bar

I then did

   curl -D- https://54.162.86.23/'foo?bar' -H'Host: khanacademy.org'

and it said
   curl: (51) SSL: certificate subject name '*.khanacademy.org' does not match target host name '54.162.86.23'
which is a limit to the testing I can do until I change DNS.  But at
   least it didn't complain about a self-signed certificate, or lack
   of certificate, or anything like that.

I also did (to test https support ignoring certificate issues):

   curl -D- -k https://54.162.86.23/'foo?bar' -H'Host: khanacademy.org'

and it said

    HTTP/1.1 301 Moved Permanently
    Server: nginx/1.6.2
    Date: Tue, 07 Oct 2014 23:30:25 GMT
    Content-Type: text/html
    Content-Length: 184
    Connection: keep-alive
    Location: https://www.khanacademy.org/foo?bar

Reviewers: alpert

Reviewed By: alpert

Differential Revision: http://phabricator.khanacademy.org/D13700