Tentacle extration directory?

Hi,

I need to run a PS script at the tentacle that must access some files in the root of my web application. Before the xml transformation action is run.

What variable for the extration directory can I use to get “web.config” for example?

What custom script event should I use to access the files before xml tranform?

Thanks.

Hi,
As outlined in our documentation there are various places that you can provide PowerShell scripts to be execute throught the deployment process. In your case I would recommend creating a preDeploy script and either placing it in your NuGet package, or including the script in the Octopus Deploy Custom deployment scripts feature configured on your deployment step.

From within the deployment step itself the variable you can use to access the installation location is Octopus.Action.Package.InstallationDirectoryPath. If you want this variable from a subsequent step you can use the action name as an indexer and get access to it via Octopus.Action[ActionName].Output.Package.InstallationDirectoryPath, obviously substituting ActionName with the actual name of your previous step. Further details about some of the other variables are available in our docs here.

Please let me know if you need any further information on getting this deployment configured. Once you get familiar with Octopus Deploy and read some of our helpful documentation I’m sure you will find it quite simple to use.
Thanks again,
Robert

Yes, works. Thanks.

Unrelated: In these cases should I close the discussion?

Thanks for getting back to me with your results.
Feel free to leave these tickets open as other users may come across it in future and have something to add.
Cheers,
Robert