DEV Community

Discussion on: What is your most recent "Aha!" moment?

Collapse
 
mpbizdev profile image
Martin Pelletier • Edited

It was for a WebJob on Azure. I had to schedule a sitemap generator but I had no idea where, relatively to the executable, I could place the site map. One of those "so simple it's hard to find" kind of questions. Turns out that the default path is d:\home\site\wwwroot\, but the best approach is to fetch the environment variable for it, which is called WEBROOT_PATH. Having that, it was easy to just add wherever the sitemap was supposed to be and schedule the WebJob.