Allow setting custom host names for the worker config.

Relevant for upcoming caching services.
Fix erb template.
Add configuration for S3 cache details.