private static void AddConfigurationMounts(IConfiguration config, MountsTable mountsTable)
 {
     // Add configuration mounts
     foreach (var mount in config.Mounts)
     {
         mountsTable.AddResolvedMount(mount, new LocationData(config.Layout.PrimaryConfigFile, 0, 0));
     }
 }
Example #2
0
        private static bool AddConfigurationMountsAndCompleteInitialization(IConfiguration config, LoggingContext loggingContext, MountsTable mountsTable)
        {
            // Add configuration mounts
            foreach (var mount in config.Mounts)
            {
                mountsTable.AddResolvedMount(mount, new LocationData(config.Layout.PrimaryConfigFile, 0, 0));
            }

            if (!mountsTable.CompleteInitialization())
            {
                Contract.Assume(loggingContext.ErrorWasLogged, "An error should have been logged after MountTable.CompleteInitialization()");
                return(false);
            }

            return(true);
        }