/// <summary>
        /// The main entry point for the application.
        /// </summary>
        public static void Main(string[] args)
        {
            ArgumentsDictionary argsDict = ProcessArguments(args);

            //this logger is not being used at the moment
            logger = new Logger((string)argsDict["Log"]);

            Settings.InitSettingsFromFile((string) argsDict["ConfigFile"]);

            HomeService homeService = new HomeService(logger);

            homeService.Start(null);

            while (!serviceExited)
            {
                System.Threading.Thread.Sleep(10000);
            }

            Environment.Exit(homeService.ExitCode);
        }
        /// <summary>
        /// Starts the home service that connects us to the cloud using the gatekeeper
        /// </summary>
        private void InitHomeService()
        {
            if (string.IsNullOrWhiteSpace(Settings.HomeId))
            {
                logger.Log("Cannot start home service without a configured home id. What is going on?");
                return;
            }

            HomeOS.Shared.Gatekeeper.Settings.HomeId = Settings.HomeId;
            HomeOS.Shared.Gatekeeper.Settings.ServiceHost = Settings.GatekeeperURI;

            homeService = new Gatekeeper.HomeService(logger);
            homeService.Start(null);
        }