Creating an enumerable by calling a function returning enumerables The purpose of the application is very simple.
PlantList is a object containing a list of PlantConfiguration.

Each PlantConfiguration has two schedules: HourlySchedule and DailySchedule, as well as a TimeZone.

The program reads a PlantList object, stored as a JSON file in the settings, and returns an enumerable of Schedule, containing all the HourlySchedules, and the DailySchedule if it is midnight in a plant's timezone.

In addition to general comments about the code, I am looking for a way to improve the loop. Indeed, using the Concat feature to smash together all schedules as they come feels sub-optimal, and I figure this is a good occasion to learn about a new pattern.

public class Program
    {
        private readonly static log4net.ILog log = LogHelper.GetLogger();

        public static void Main()
        {
            var container = new UnityContainer();
            container.RegisterType&lt;IPlantRepository, JsonPlantRepository&gt;();

            IPlantRepository serverRepository = container.Resolve&lt;IPlantRepository&gt;();
            var plantList = serverRepository.GetPlants(MySettings.Default.Servers);

            if (MySettings.Default.Disabled == true)
            {
                log.Fatal("Script disabled");
                return;
            }

            UpdateValues(plantList);
        }

        private static void UpdateValues(PlantList plantList)
        {
            DateTime utcTopHourDate = GetUtcTopHourDate();
            IEnumerable&lt;KpiSchedule&gt; schedulesToUpdate = new List&lt;KpiSchedule&gt;();
            foreach(PlantConfiguration plant in plantList.Plants)
            {
                schedulesToUpdate = schedulesToUpdate.Concat(GetScheduleList(utcTopHourDate,plant));
            }
            //... Do stuff with the schedule list
        }

        private static IEnumerable&lt;KpiSchedule&gt; GetScheduleList(DateTime utcTime, PlantConfiguration plant)
        {
            var localDate = TimeZoneInfo.ConvertTimeFromUtc(utcTime, server.TimeZone);
            List&lt;KpiSchedule&gt; returnList = new List&lt;KpiSchedule&gt;
            {
                plant.HourlySchedule
            };

            if (localDate.Hour == 0)
            {
                returnList.Add(plant.DailySchedule);
            }

            return returnList;
        }

        private static DateTime GetUtcTopHourDate(int ForceHour = -1)
        {
            return new DateTime(
                DateTime.UtcNow.Year,
                DateTime.UtcNow.Month,
                DateTime.UtcNow.Day,
                DateTime.UtcNow.Hour,
                0,
                0,
                DateTimeKind.Utc
            );
        }
    }
}
There is no need to create lists and add items to the lists when working with enumerables; yield is your new best friend.

As written, GetScheduleList() is messy to unit test so we can push the condition up a level and then use yield

private static IEnumerable&lt;KpiSchedule&gt; GetScheduleList(PlantConfiguration plant, bool includeDaily)
{
    yield return plant.HourlySchedule;
    if (includeDaily)
    {
        yield return plant.DailySchedule;
    }
}


To aggregrate the schedules for each plant we can use SelectMany().

private static IEnumerable&lt;KpiSchedule&gt; GetAllSchedules(IEnumerable&lt;PlantConfiguration&gt; allPlants, bool includeDaily)
{
    return allPlants.SelectMany(p =&gt; GetScheduleList(p, includeDaily));
}


We can now revise UpdateValues() to something like

private static void UpdateValues(PlantList plantList)
{
    DateTime utcTopHourDate = GetUtcTopHourDate();
    var includeDaily = CheckIncludeDaily(utcTopHourDate);

    var schedulesToUpdate = GetAllSchedules(plantList.Plants, includeDaily);
    //... Do stuff with the schedule list

}


or even

private static void UpdateValues(PlantList plantList)
{
    DateTime utcTopHourDate = GetUtcTopHourDate();
    var includeDaily = CheckIncludeDaily(utcTopHourDate);

    var schedulesToUpdate = plantList.Plants.SelectMany(p =&gt; GetScheduleList(p, includeDaily));
    //... Do stuff with the schedule list
}