Is it a good idea to put e.g. autofac/ninject in a static class that I can access is from different assemblies/projects?
static class MyContainer
{
static IoCContainer ContainerOfCurrentRuntimeContext;
}
If I use this, I can use the same IoC-context in different projects.
No, this approach will add two new problem: singleton and service locator patterns (both counted as anti-patterns). As result your code will be coupled to new dependency: your DI contaner.
Usually you could overcome limitations of using service locator, but this will not worth doing, as it’s much simple to introduce composition root for DI.
By the way, you could have one configuration and use it in all your different projects.