We use TeamCity Octopus add on to create releases getting the information from many builds. We’re getting package information from these builds and passing on package version to octo.exe via --package PackageName:version. Sometimes a misconfiguration on one of the builds is creating the release with the wrong version, and Octopus defaults to latest available.
We would like to fail that step if any “latest” version is used. Is there a way we can set this at the project level? Octo.exe seems to be unable to do so.
It may be the same, but the issue is slightly different. When a build fails with a special kind of failure, sometimes version is not passed along, and we’re getting this message:
|[08:18:48]|The package version for some steps was not specified. Going to try and resolve those automatically
|[08:18:48]|Finding latest package for step: StepN
What I want to do is fail the release creation if a version is not specified. You think it will be addressed as part of the bug you mentioned? Is there any way to force specifying a package value?
@donny.bell we do (at least for successful builds), but sometimes build failures miss the package version and we don’t pass “–package” for certain packages. Is there a way to fail the package creation if the process has one package reference not included on the “–package” parameters?
There may be a way to do this in TeamCity if you are using a variable to populate the value for package version in the build. However, there isn’t a way to fail this on the Octopus side since this is an optional value.
I did have a thought, though. This is not something I have tested. However, perhaps you could use a purposely different version number as a fallback in the event a version is not generated normally so that it would fail the Channel Version Rules in Octopus:
Let me know if you have any additional questions or if I can assist with anything else.
Hi @donny.bell, we haven’t implemented channels yet, and due to the size of the deployments it will be a hard change. We might do it, since it was discussed many times.
About the TeamCity variable, we use variables for that, but only a single %octoParameters% value where all of the “–package:Package:Version” strings. What would be your thought here?
In any case, this is currently not supported and I guess we’ll have to implement something on our build server