public static IConfigurationBuilder AddCubesConfigurationProvider(this IConfigurationBuilder configuration,
                                                                          ICubesEnvironment cubes)
        {
            var cubesConfig = new Dictionary <string, string>
            {
                { $"{CubesConstants.Configuration_Section}:Version", cubes.GetEnvironmentInformation().FullVersion },
                { $"{CubesConstants.Configuration_Section}:RootFolder", cubes.GetRootFolder() },
                { $"{CubesConstants.Configuration_Section}:AppsFolder", cubes.GetAppsFolder() },
                { $"{CubesConstants.Configuration_Section}:LogsFolder", cubes.GetFolder(CubesFolderKind.Logs) },
                { $"{CubesConstants.Configuration_Section}:SettingsFolder", cubes.GetSettingsFolder() },
                { $"{CubesConstants.Configuration_Section}:StorageFolder", cubes.GetStorageFolder() },
                { $"{CubesConstants.Configuration_Section}:TempFolder", cubes.GetFolder(CubesFolderKind.Temp) },
                { $"{CubesConstants.Configuration_Section}:StaticContentFolder", cubes.GetFolder(CubesFolderKind.Content) },
                { $"{CubesConstants.Configuration_Section}:BinariesFolder", cubes.GetBinariesFolder() },
            };
            var swaggerFiles = cubes
                               .GetSwaggerFiles()
                               .Select((f, i) => new KeyValuePair <string, string>($"{CubesConstants.Configuration_Section}:SwaggerFiles:{i}", f))
                               .ToList();

            foreach (var item in swaggerFiles)
            {
                cubesConfig.Add(item.Key, item.Value);
            }

            var allAssembliesWithControllers = cubes
                                               .GetActivatedApplications()
                                               .SelectMany(app => app.AssembliesWithControllers.ToList())
                                               .Select((f, i) => new KeyValuePair <string, string>($"{CubesConstants.Configuration_Section}:AssembliesWithControllers:{i}", f))
                                               .ToList();

            foreach (var item in allAssembliesWithControllers)
            {
                cubesConfig.Add(item.Key, item.Value);
            }

            configuration.AddInMemoryCollection(cubesConfig);
            return(configuration);
        }