Generate presigned URLs based upon Host: or preconfigured s3_external_url setting

This patch extends the generate_presigned_url so that one can pass a
fallback vhost url. If the s3_external_url is not found, then it will
check if we are generating urls based upon vhosts. If it is, then use
the vhost. Otherwise, fallback to using the same URL we use to access
bookshelf or S3.