Is it possible to run an IHostedService on a service provider that is not the one provided by ConfigureServices?
I am working on a library that helps configure various environments and each one has its own context (the environment context is driven by service providers). I can call .AddHostedService<>(); just fine, it doesn't throw, but the service constructor never gets called and the service doesn't start.
Edit:
I can manually kick off the services like Andy suggests in the answers, but where would that happen?