Octopus Command Line - Exclude Specific Targets

Hello, I’m trying to use the Octopus Command Line to deploy a release. Within my Octopus Console, there is an option to exclude specific targets from a certain deployment if you deploy to an entire environment. I do not see this as an option within the Octopus Command Line “Deploying Releases” documentation.

Is there a flag for this? Will it be added in the future?
I’m hoping for something like this:

octo deploy-release --project ScriptHere --releaseNumber 0.0.2 --deployto Production --excludeTargets [listhostshere]

Hi,

Thanks for getting in touch! Unfortunately there’s no current flag in Octo.exe’s deploy-release command to exclude targets from a deployment. However we agree it should be added, especially since this option is already available in the UI. I’ve raised the following enhancement to get this implemented, and you can track its progress here.

In the meantime, would the --specificmachines flag help at all? You’d have to specify all machines except those to be excluded, so may not be ideal.

Thanks for bringing this to our attention, and don’t hesitate to reach out if you have any further questions or concerns moving forward. :slight_smile:

Best regards,

Kenny

Thanks for replying and also for the suggestion. Unfortunately it wouldn’t help because I only need to exclude 1 machine from each environment and the environments have hundreds of hosts.
How long do the enhancements usually take to get implemented?

Thanks again.

Hi,

I have begun adding this enhancement and should hopefully have it done and tested and ready for release by the end of this week.

Thank you and best regards,
Henrik

Hi sir, just want to check and see if this is out yet and what’s the easiest way to update my command line tool?

Thanks!

Hi,

Yes, the enhancement has been released and you can download the latest version of our Command line tools here.

Thanks,
Henrik

Thank you very much!

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.