I am seeing an issue where some steps in a deployment are getting skipped because of no targets available. Running Octopus version: 2021.3.12372
When I select the Deployment Targets as you can see there are 2 healthy targets but only one included.
I then have to select the Include all applicable deployment targets option and the deployment will pass.
Is this a bug or an issue that has been reported before?
Thanks for getting in touch!
The first thing to check here would be that the selected target has the correct Role assigned for those steps. It could be that your deployment process has a mixture of roles and this target doesn’t have all of them.
Are you able to confirm that the target
IN01WEVD0034 has the role
Yes Paul we have two roles in this deployment, 5 step runs in one role(EOL-Web-Server) and 2 steps run in another role (EOL-ADFS-Server), each roles uses different servers ,
IN01WEVD0034 has the role EOL-Web-Server and EOL-ADFS-Server is assigned to another server, this happens when we create and deploy a release from jenkins using octo.exe, however when we deploy manually we have to select include all the targets and redeploy.
During the automated deployment from jenkins to octopus, it will only select one/specific target, but when we manually include all targets and deploy, it remembers the setting for that release for future deployments, is it something with release creation, do we need to pass any specific parameter to include all targets while creating or deploying a release from octo.exe?
When initiating a deployment from within the UI, selecting Re-Deploy will save the deployment settings from the last deployment, including the
Include\Exclude Targets setting. If you select the
Deploy To option, a new deployment will be generated, and the
Include\Exclude Targets setting will have the default
All Targets option selected.
When you say that deploying from Jenkins only selects one specific target, is that intentional or something you want to change?
By default, any deployments initiated from the Octo CLI should include all targets, same as the UI. The only way to limit it to a single target would be to pass the
--specificMachines=VALUE argument (or
So, if you want the deployment from Jenkins to target all machines, it would be worth double-checking the command it is running to see if either of those arguments has been added.
No those parameters were never passed, and we want it to be deployed to all the targets, which is not happening, please find our octo cmd below
octo.exe create-release --project $Project --version $ENV:PIPELINE_VERSION --packageVersion $ENV:PIPELINE_VERSION --server $Octopus_URL --apiKey $Api_key --space=$Space_Id --channel=$Branch --package Maintenance:0.0.1 --ignoreExisting
octo.exe deploy-release --project $Project --releaseNumber $ENV:PIPELINE_VERSION --deployto Dev --server $Octopus_URL --apiKey $Api_key --channel=$Branch --space=$Space_Id --tenant=int --progress --waitForDeployment --deploymentTimeout=“2”
That is unusual. If you want to send across the full log from Jenkins I can take a look and see if anything stands out to explain the behaviour.
I can see that the command is targeting a specific tenant,
--tenant=int, I’m assuming that all of the targets you want this deployment to run for are correctly associated with that tenant?
I found out the issue, we have a orchestration project to deploy multiple projects, where we have a parent step running on EOL-Web-Server role, hence subsequent child steps are only running only steps associated to EOL-Web-Server role and skipping EOL-ADFS-Server role.
This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.