Deploy Package Twice not Working

I have a 4 step project setup, the first two each deploy a different package to different location. The next two steps deploy the same package to two locations. Or at least they should do.

Only the first deployment in the second two steps ever appears to happen. If I shuffle these two in the order it proves both tasks are configured correctly.

Why would Octopus just silently skip one of the last two steps?

Hi Jammar,

Octopus assumes that a package only needs to be deployed once, and so the second time it probably logs something to the effect of “the package has already been installed” and so it is skipped.

To work around this you can tick the ‘Force package redeployment’ checkbox when deploying the project.

Paul

We have a project which we want deployed in two separate places with two separate configs. In all other respects they are identical, and they have the same NuGet package.

This will happen in every deploy, and it is critical that neither step be missed. It’s looking like our only solution is to create two separate NuGet packages?

Hi Paul,

Is there any way in which a Step can be marked as ‘Always/Force Deploy’?

I have the same scenario - one Package which I want to deploy in multiple steps to different directories…

Thanks

There are many such request, and maybe mutli tenancy on the road map sorts this out. I think I am gonna hack this by having

Step 1 - deploy to a common folder
Step 2 - powershell copy from common to deployment folder for Site1
Step 3 - powershell copy from common to deployment folder for Site2
etc etc…

I don’t make use of roll backs or anything so I suppose this suits me fine, but it probably far from best practice…

But it would be nice to be able to Force Deploy… will keep an eye out for multi tenancy.

Hi Anton,

Thanks for getting in touch! Under a project you can set “Package redeployment” to "Always deploy all packages"
Then in the deployment itself you can set "Force deployment of packages that are already installed"
This will allow you to have multiple package steps deploy the same package and then move them using the Custom Installation Directory feature.

But you are correct, multi-tenant deployments will do this more elegantly.

Hope that helps!
Vanessa

Woops! Can’t believe I didnt see that setting.

Thanks for letting me know!