Deploying specific version from TeamCity

Hi all,

I have 1 build configuration in TeamCity that deploys to Test site in Octo.

I ran into the same problem as here: http://help.octopusdeploy.com/discussions/problems/6074-deploying-from-teamcity-picks-up-the-wrong-nuget-package-version

My deploys are always 1 version behind. Is there a way to specify that it has to wait for the exact version as sent by TeamCity instead of just taking the first package it finds?

I checked the build log from TC and I saw this command is executed:
octo.exe create-release --server http://127.0.0.1:8001 --apikey SECRET --project Demo --enableservicemessages --version 2.0.0.232 --deployto Test

But probably it can’t find the nuget package 2.0.0.232 it just uses 2.0.0.231, in my opinion this is quite dangerous and can lead to some unexpected deployments.

Can I add --packageversion=%build.number% to TeamCity’s custom parameter, or better --package %build.number%

Thanks.