title: Using a custom ServiceHostFactory in a WCF Service Library project
body: <p>I'm programming a WCF service that internally relies heavily on Inversion of Control. I would like to bootstrap / initialize my IoC container inside a custom ServiceHostFactory. I've read some examples of different hooks that are available, but none of them seem to work for me.</p>
  
  <p>This <a href="http://www.lostechies.com/blogs/jimmy_bogard/archive/2008/07/29/integrating-structuremap-with-wcf/printerfriendly.aspx" rel="noreferrer">approach</a> is the one I'd prefer to use (custom IServiceBehavior, IInstanceProvider, ServiceHost and ServiceHostFactory) but the last step is to signal to the service to use my custom ServiceHostFactory inside my serivce's *.svc-file. I don't have one of those since the project type is a WCF Service Library - not a WCF Service Application. Is there a way I can tell WCF to use my ServiceHostFactory in the App.config file?</p>