I've a requirement to run some code on the scheduler app instance in DXC alongside our scheduled job, which creates and schedules jobs according to Azure Service Bus messages.
At the moment i'm trying to read the local machines 'hostname' and provide something in config that matches that hostname to let us know we are on the correct machine or not for starting our extra code. Problem i have is the hostname appears to be changing on each deploy, or at least isn't completely static
Is there a simple way to tell if scheduled jobs are enable in the current instance of EpiServer?
Easiest way could be to look for the enableScheduler in the Episerver config?
Thanks @David, i thought of that approach, but couldn't find a clear way to access those settings, as it's not <appSettings> but <applicationSettings> instead.
Haven't tried myself, but Settings.Instance.EnableScheduler might work.
Or you can get the Settings instance by dependency injection, same thing.