Welcome to the Inedo Forums! Check out the Forums Guide for help getting started.
If you are experiencing any issues with the forum software, please visit the Contact Form on our website and let us know!
Possible to set Preload Enabled to true in IIS:EnSureSite?
-
Hi,
Is there any way I can make sure the setting "Preload Enabled" is set to true when I IIS::Ensure-Site
I would like my iis apps to be preloaded and stay up always...
Thanks,
Justin
-
It's been a while, but I believe we investigated this a little while back, but discovered it wasn't possible/feasible to do with the API we were using. That would have been in the .NET4+ days, not .NET6+, so it may have changed.
I don't remember
Here's the code we use to bind the Otter configuration to
Microsoft.Web.Administration
libraries: https://github.com/Inedo/inedox-windows/blob/master/Windows/InedoExtension/Configurations/IIS/IisSiteConfiguration.csIt might be trivial now, and we'd be happy to accept a pull request if you're able to figure/try it out!
Cheers,
Alana
-
@Justinvolved said in Possible to set Preload Enabled to true in IIS:EnSureSite?:
Preload Enabled
Hey Alana,
I will definitly give it a go. From what I can see in the Microsoft.Web.Administration docs it should be possbile.
To prevent me creating a fully untested PR, could you help me get started with setting up a dev environment for this? Then I can at least run a couple of tests in my own environment before submitting, but I'm not sure where to start...
Thanks,
Justin
-
Hi @Justinvolved,
The easiest way to setup a test environment for this would be to setup an instance of Otter (free edition is fine). Then once you have checked out https://github.com/Inedo/inedox-windows and made your changes, you can package the extension using the Inedo Extension Packager. This is available as a .NET tool. You can then navigate to the extensions page and upload the extension file to Otter. You may need to modify the
AssemblyVersion
inAssemblyInfo.cs
to a version newer than the installed version to get it to pick it up as the lastest. Alternatively, you can copy that extension file to theExtensions.ExtensionsPath
and restart Otter to have it pick up as well.The command I typically run to package the extension is:
inedoxpack pack InedoExtension Windows.upack -o --build=Debug
I run that command from the the solution file's directory.
Hope this helps! If you have any questions, please let me know.
Thanks,
Rich