Blue Green - installation path for the other environment

I need access to the other enviroment’s installation path, so I can pass this to a variable substitution step.

I have modelled the roles as per this: Green/Blue deployment: how do I do IIS Reset in the *other* environment

ie I have a “Web Server” role, and an “Inactive Web Server” role.

Does this make sense?

Thanks

James

edit: I can’t see how to add this to another category (Modelling for example) so apologies if this is in the wrong place.

I am on version 2018.3.13

Hi James,

Thanks for getting in touch, your patience is greatly appreciated.

Based on the information provided in your query, can you please include some additional information as to what each environment’s installation directories look like?

If the directories are the same barring the environment name, perhaps you could have two values and manually build up the installation directory that you require with the this being the only difference by scoping them accordingly to the respective environment?

As an example, if your installation folder is C:\Octo\Dev\Package Version this could be instead C:\Octo\Dev\#{Octopus.Action.Package.PackageVersion} for the Dev Environment and C:\Octo\Prod\#{Octopus.Action.Package.PackageVersion} for the Prod Environment by scoping to these variables to each respective environment.

Or even simpler if you have something like C:\Inetpub\wwwroot\blue & C:\Inetpub\wwwroot\green, you could hardcode both values, scoping each to the other environment.

If I’ve misunderstood your query in any way, or you require further assistance please let me know.

I look forward to hearing back from you :slight_smile:

Kind Regards,

Reece

Hi

I’ve managed to do this just now!

At the end of my deployment I save the Package.InstallationDirectoryPath to a project variable, using the save output variable community template. I had to amend it use a SaveAs parameter (I needed 2 paths saving). Therefore the next deployment can use those project variables.

Thanks for giving some thought to the problem.

James

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.