I’m using Web Deploy - Publish Website (MSDeploy) step from the library. This step uses the work folder of the previous Deploy nuget package step. But when the web deploy step is starting the folder of the previous step is already deleted. How can I prevent the folder to e deleted?
Error:
Publishing Website
Exception calling “CreateObject” with “2” argument(s): “Could not find file ‘C:
\Octopus\Work\20151211110341-10’. Learn more at: http://go.microsoft.com/fwlin
k/?LinkId=221672#FileOrFolderNotFound.”
Thanks for reaching out. That step template doesn’t use the the work folder of the Nuget Deploy step, it uses the InstallationDirectoryPath. Unlike the working folder, the InstallationDirectoryPath is not deleted at the end of the deployment. You can get the full path from a subsequent step using the variable below
Hi, I am having same problem, but looking at the output, it looks like the MSDeploy Step is using the “Work” folder, but the file it’s expecting isn’t there.
True v2.0.50727 C:\WINDOWS\assembly\GAC_MSIL\Microsoft.Web.Deployment…
11:03:18Info
Finding path to package step: Nuget
11:03:19Info
Package was installed to: D:\Octopus\Work\20160211110217-24
11:03:19Info
Skipping delete actions on App_Data
11:03:19Info
Publishing Website
11:03:19Verbose
Exception calling “CreateObject” with “2” argument(s): "Could not find file
11:03:19Verbose
’D:\Octopus\Work\20160211110217-24’. Learn more at:
Thanks for sharing that info. May I ask why are you using that MSDeploy step template? I’m asking because 95% of that step’s users used to use it to deploy to Azure, and as of Octopus 3.1 we offer way better support for Azure deployments right out of the box.
Is there a specific reason why you want to use that step template?
No, just found an article online… All I want to do is package and deploy to an azure website. If I can do without that template then great. Do you have a pointer to an updated doc?
Many thanks for the prompt reply. Having done this, I have just noticed a
"we’re going to deprectate Azure web apps as a target", so can I share with
you my set up so I can make sure I am doing this right going forward?
I run a small saas product, with each customer having their own db and
azure web app. They all run the same code, but I want to be able to deploy
to all or selected customers in a manner determined by the features
released, so:
Customer 1 - Web App 1 + SQL DB 1
Customer 2 - Web App 2 + SQL DB 2
etc
In the previous way, I could set up each of my customer as an "Environment"
then choose which ones get any new Release I create. Can you share how I
can achieve this without Environments, as it looks like I would need to
create 1 Project for each Customer (and create releases for each), making
managing versions even more complicated? Am I missing something?
Right now the easiest way to manage you multi-client scenario would be to either:
A) Use a Channel per customer with channel-scoped variables for db connection strings and that kind of stuff. This will allow you to use a single project for all of your customers.
Thansk for the info. Are you going to deprecate the Azure target before
3.4 - i.e. shall I start using this then migrate to the new model when 3.4
is out. Do you have an indicative timeframe?