We’re trying to include the variable Octopus.Environment.Name in a powershell script that creates a file.
if we reference the variable directly like so .. /tf:"D:\EXTRACTS\${Octopus.Environment.Name}_Logging.dacpac"
The variable shows as being populated if we enable OctopusPrintVariables it looks like it’s got a valid value but it doesn’t carry into our powershell commands,
As a work-around I’ve created a project wide variable called EnvironmentPrefix with a value of #{Octopus.Environment.Name}
And it works fine…
Just thought I’d let you know… (assuming it’s not something we’re doing wrong?)