Variable subsitution not working for Octopus variables (deployment folder in our case)

We have variable substitution and config transformations working perfectly apart from when we need the folder the project has been deployed to. We tried using the following “#{Octopus.Action[Test Copy].Output.Package.InstallationDirectoryPath}” but it just ends up like that in our config file. How do i get the path to the deployment folder as i need to specify the full path to a dll file to be loaded in a transformation and the full path must be in the config not worked out in code in this case.

Before we deployed to a fixed folder but now we are just letting octopus use the default folders it uses but that means we can’t hard code the dll path any more and parts of our system are failing because of it.

For those interested #{OctopusOriginalPackageDirectoryPath} seems to work as long as you don’t set a custom directory which we are not using.

Also the page below tells you how to get it to list all the variables available in the logs which helpped us work this out.