Asset host and link_to

i’ve defined an asset host for my Rails app and all files uploaded
through
it are accessed via the asset host. How should i access the config
object in
order to generate correct urls for these files using link_to?