Thanks for reaching out. Could you please follow the below steps so we can help you with the troubleshooting?
Create a separate Octopus Project. Add only 2 steps to this project: “IIS App Pool Create” & “Update Recycle Settings”. What we want here is to have a deployment that only has the two steps we want to troubleshoot.
Create a new release (so the new variables take effect) and deploy it. If you are having this problem in all your machines, just deploy to one of them to avoid extra noise in the log.
Thanks for the quick response. On the process of debugging the problem using the steps provided by you, I attained the solution. This is what I did.
I removed double quotes for the time which was suggested in Examole
<<<********************>>>>
Application pool periodic recycle time : “03:00:00”
A specific local time, in 24 hour format, when the application pool is recycled.
Example: “00:30:00” for half an hour past midnight.
<<<********************>>>>
Just used 03:00:00 instead of "03:00:00"
Because below error made me do it
Cannot convert value "“01:00:00"”
Used explicit typecast in Custom step template of ‘IIS AppPool - Update Recycle Settings’ after importing from Library.
-Added [TimeSpan] for the variable.
$periodicRecycleTime = [TimeSpan]$OctopusParameters[“PeriodicRecycleTime”]