protected override void Execute() { if (PasswordIsIncorrect()) { Log.Error("Invalid deploy password, aborting deployment"); return; } InDeployContext(context => { context.DeployUnit.StartingDeploy(context.NewVersion, context.LogFileName, _user, _parameterValues); Log.InfoFormat("Starting deployment of {0}, Version: {1}, {2} {3}", _deployUnit.Name, _version.Number, _parameterValues.GetLogString(), GetCurrentUserInfo()); foreach (var stepFunc in _steps) { var step = stepFunc(); Log.InfoFormat("Executing deploy step: {0}", step.GetType().Name); step.Execute(context); } context.DeployUnit.DeployCompleted(); Log.Info("Deployment completed"); }); }