IIS Deployment question

Making progress on getting Octopus up and running for one of our smaller projects. I’m running into some problems on deploying to a web site, and I’m thinking there may be an issue with case-sensitivity. Check the log below, properly scans the config files (“Scanning configuration file”), but a a few lines later reports that it can’t find a web.config file. Currently, the web config file is Web.config. I’m going to try and rename it to lower case to see if that’s the problem.

2011-06-30 20:36:46 INFO Deploying release ‘1.0’ of project ‘Digital Fulfillment’ into environment 'Dev’
2011-06-30 20:36:46 INFO Downloading NuGet package DigitalFulfillment 1.0 from feed: 'http://ironforge:8080/nuget
2011-06-30 20:36:46 DEBUG Completed download of NuGet package DigitalFulfillment 1.0
2011-06-30 20:36:46 DEBUG Uploading package DigitalFulfillment 1.0 to tentacle http://eavdevscar02:10933
2011-06-30 20:36:55 DEBUG Sending chunk 1 of 11
2011-06-30 20:36:55 DEBUG Sending chunk 2 of 11
2011-06-30 20:36:55 DEBUG Sending chunk 3 of 11
2011-06-30 20:36:55 DEBUG Sending chunk 4 of 11
2011-06-30 20:36:55 DEBUG Sending chunk 5 of 11
2011-06-30 20:36:55 DEBUG Sending chunk 6 of 11
2011-06-30 20:36:55 DEBUG Sending chunk 7 of 11
2011-06-30 20:36:55 DEBUG Sending chunk 8 of 11
2011-06-30 20:36:55 DEBUG Sending chunk 9 of 11
2011-06-30 20:36:55 DEBUG Sending chunk 10 of 11
2011-06-30 20:36:55 DEBUG Sending chunk 11 of 11
2011-06-30 20:36:56 DEBUG Package DigitalFulfillment 1.0 successfully uploaded to tentacle http://eavdevscar02:10933
2011-06-30 20:36:56 DEBUG Deploying package DigitalFulfillment 1.0 to tentacle http://eavdevscar02:10933
2011-06-30 20:37:02 INFO Deployment successful. Tentacle output follows:
2011-06-30 20:37:25 DEBUG Tasks will be run in the following order:

  • PowerShellPreDeployScript
  • XmlConfigTransforms
  • XmlConfigVariables
  • PowerShellDeployScript
  • Installers
  • IisWebSite
  • PowerShellPostDeployScript
    2011-06-30 20:37:25 DEBUG Start: Executing RemoveAttributes (transform line 18, 18)
    2011-06-30 20:37:25 DEBUG on /configuration/system.web/compilation
    2011-06-30 20:37:25 DEBUG Applying to ‘compilation’ element (source line 12, 6)
    2011-06-30 20:37:25 DEBUG Removed ‘debug’ attribute
    2011-06-30 20:37:25 DEBUG Removed 1 attributes
    2011-06-30 20:37:25 DEBUG End: Done executing RemoveAttributes
    2011-06-30 20:37:25 INFO Updating any .config files
    2011-06-30 20:37:25 DEBUG Scanning configuration file: C:\Octopus\Tentacle\Applications\DigitalFulfillment.1.0\content\Web.config
    2011-06-30 20:37:25 DEBUG Scanning configuration file: C:\Octopus\Tentacle\Applications\DigitalFulfillment.1.0\content\Web.Debug.config
    2011-06-30 20:37:25 DEBUG Scanning configuration file: C:\Octopus\Tentacle\Applications\DigitalFulfillment.1.0\content\Web.Release.config
    2011-06-30 20:37:25 INFO Installing any Installers
    2011-06-30 20:37:25 DEBUG Scanning assembly: C:\Octopus\Tentacle\Applications\DigitalFulfillment.1.0\content\bin\Fulfillment.dll
    2011-06-30 20:37:27 DEBUG A web.config file was not found, so no IIS configuration will be performed.
    2011-06-30 20:37:27 INFO Deployment complete!

Hi Kevin,

Variables are applied to web.config files in any child directory. However, up until recently, the IIS convention only looked for web.config files in the root of the package.

The latest build contains a fix for this. However, I’d suggest that the /content root folder probably isn’t needed anyway - that’s a NuGet visual studio convention, not a requirement of general NuGet packages. Octopus will extract the contents of your package as-is.

The build is available from:

Paul

Okay, I got it. Great news! Glad to hear about the structuring of the NuGet file, I wasn’t exactly sure how to package things up, so I was rolling with the docs I read on their site. I’m going to go ahead and adjust stuff around here momentarily and see where that takes me.

I’m close, I can feel it… :slight_smile:

Installed the latest version of octopus and tentacle, and now my tentacle server is having problems resolving some autofac stuff. This is still on the Win2k3 server.

Taken from fuslogvw on the tentacle server:

The operation failed.
Bind result: hr = 0x80070002. The system cannot find the file specified.

Assembly manager loaded from: C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\clr.dll
Running under executable C:\Octopus\Tentacle\Agent\Tentacle.exe
— A detailed error log follows.

=== Pre-bind state information ===
LOG: User = NT AUTHORITY\SYSTEM
LOG: DisplayName = Autofac.resources, Version=2.4.5.724, Culture=en-US, PublicKeyToken=17863af14b0044da
(Fully-specified)
LOG: Appbase = file:///C:/Octopus/Tentacle/Agent/
LOG: Initial PrivatePath = NULL
LOG: Dynamic Base = NULL
LOG: Cache Base = NULL
LOG: AppName = Tentacle.exe
Calling assembly : Autofac, Version=2.4.5.724, Culture=neutral, PublicKeyToken=17863af14b0044da.

LOG: This bind starts in default load context.
LOG: Using application configuration file: C:\Octopus\Tentacle\Agent\Tentacle.exe.Config
LOG: Using host configuration file:
LOG: Using machine configuration file from C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\config\machine.config.
LOG: Post-policy reference: Autofac.resources, Version=2.4.5.724, Culture=en-US, PublicKeyToken=17863af14b0044da
LOG: The same bind was seen before, and was failed with hr = 0x80070002.
ERR: Unrecoverable error occurred during pre-download check (hr = 0x80070002).

Here’s the error from the event log:

Application: Tentacle.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: Autofac.Core.DependencyResolutionException
Stack:
at Autofac.Core.Resolving.ResolveOperation.Execute(Autofac.Core.IComponentRegistration, System.Collections.Generic.IEnumerable1<Autofac.Core.Parameter>) at Autofac.Core.Lifetime.LifetimeScope.ResolveComponent(Autofac.Core.IComponentRegistration, System.Collections.Generic.IEnumerable'1<Autofac.Core.Parameter>) at Autofac.ResolutionExtensions.TryResolveService(Autofac.IComponentContext, Autofac.Core.Service, System.Collections.Generic.IEnumerable'1<Autofac.Core.Parameter>, System.Object ByRef) at Autofac.ResolutionExtensions.TryResolveService(Autofac.IComponentContext, Autofac.Core.Service, System.Object ByRef) at Autofac.Features.Indexed.KeyedServiceIndex2[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].TryGetValue(System.__Canon, System.__Canon ByRef)
at Octopus.Tentacle.Jobs.JobQueue.RunDeploymentsOnBackgroundThread(System.Object)
at System.Threading.QueueUserWorkItemCallback.WaitCallback_Context(System.Object)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.QueueUserWorkItemCallback.System.Threading.IThreadPoolWorkItem.ExecuteWorkItem()
at System.Threading.ThreadPoolWorkQueue.Dispatch()
at System.Threading._ThreadPoolWaitCallback.PerformWaitCallback()

Hi Kevin,

Sorry about this, that was a pretty silly bug. I’ve added some tests to make sure it doesn’t happen again and I’ve posted a new build here:

Paul