Don't drop port or path prefix when generating final S3 URL.

Fixes #273