octo.exe specify multiple different NuGet package versions by id

David Gutzmann's Avatar

David Gutzmann

17 May, 2017 08:30 PM

Hi,

is it possible to specify the NuGet package versions to be used during creation of a release by package ids instead of stepNames?

We have multiple deployment packages we have to provide versions for when we create a release. Some of them 'live' in the same Solution and get the same version number during the teamcity build. Others are 'external' to the main Solution and therefore in general have different versions than the ones coming from the main Solution. When we create a release manually in OD we have to look up the correct version for the 'external' packages in our documentation. We would like to automate the process of release creation.

We plan to have a 'releaseDependencies.json' file in source control where we state the versions of the 'external' dependencies. Teamcity will then pull this 'manifest' and kick off octo.exe to create the release providing the package versions. This file is going to be maintained by developers who do not necessarily will have knowledge of any step names in octopus deploy. Our developers do know the package ids because the .nuspec files are right there in source control. And in the end software does depend on other software, it does not depend on any step names. So I would rather like to see

{
packages: [{
id: "id1",
version: "3.1.2.3"
},
{
id: "id2",
version: "3.2.1.3"
}]
}

instead of

{
packages: [{
stepNameInSomeSoftwareWeUseToDeployStuff: "Deploy ServiceA",
version: "3.1.2.3"
},
{
stepNameInSomeSoftwareWeUseToDeployStuff: "Deploy ServiceB 2016",
version: "3.2.1.3"
}]
}

Thank You!

David Gutzmann

  1. Support Staff 1 Posted by Shane Gill on 18 May, 2017 12:16 AM

    Shane Gill's Avatar

    Hi David,

    Thanks for getting in touch.

    You can pass package ids to Octo.exe rather than step names:

    Octo.exe create-release --package id1:3.1.2.3 --package id2:3.2.1.3

    There is more in our documentation on how Octo.exe resolves package versions: https://octopus.com/docs/api-and-integration/octo.exe-command-line/...

    I hope this helps.

    Cheers,
    Shane

  2. 2 Posted by David Gutzmann on 18 May, 2017 11:52 AM

    David Gutzmann's Avatar

    Hi Shane,

    Thank you for the quick reply!

    This is exactly what I was looking for! The possibility of providing ids rather than step names is not mentioned in the documentation. You might want to consider adding that piece of information.

    Thank you!

    David

  3. Paul Stovell closed this discussion on 25 Aug, 2017 05:37 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac