Custom expression on NuGet Package ID field. Octopus Version 3.4.13


I’m trying to use custom expression on NuGet Package ID field (on deployment step) ,but its not work properly, variables was added, package exist.
Can you please assist ?


Hi Viktor,

Thanks for reaching out! The problem here is that, by the time you start to create your release, you still haven’t selected an environment to deploy to, so there’s no way for Octopus to know which variable with which scope should be used.

Judging by your screenshots, it sounds like you’d be better off using 2 Channels, one with a lifecycle that hits QA & Dev and uses the Develop package. And another one with a lifecycle for Production and Staging that uses the Release package. You’d need to have 2 steps in your deployment process, each scoped to a different channel and avoiding the usage of a variable to set the pacakge ID.

The Channels feature was really developed for scenarios like this one where you need to use different packages and lifecycles on the same project, so I really think you should give it a try. You can read more about it here:

Let me know if you have any questions.


Hi Dalmiro,

Thank you for your answer.
I will be use this strategy.

Thanks you,