Skip Step When Auto Deploying When Machine Becomes Available for Deployment?

daniel.auger's Avatar

daniel.auger

12 Oct, 2017 06:20 PM

We have a project with an automatic deployment trigger for the "Machine becomes available for deployment" event group. Ideally we'd like to skip a step in our deployment process if the deployment is triggered by this event. Is there a way to do this? It looks like we might be able to do this using an expression in the step's run condition, but I'm unsure of the exact syntax to use if this is possible.

Is this possible? If so, what is the syntax?

  1. Support Staff 1 Posted by Tom Peters on 13 Oct, 2017 12:30 AM

    Tom Peters's Avatar

    Hi,
    Thanks for getting in touch!

    We don't expose any special variables during deployment that can be used to determine how the deployment was triggered. This means you can't use a custom expression for a step's run condition to disable it based on how it was triggered.

    We currently don't allow this because deployments usually should be treated the same regardless of how they are triggered. Could you tell me a little more about why you have a step that you want to disable if the deployment was automatically triggered by a specific event? The reason I am asking is because there may be other ways of solving your specific problem.

    As a workaround, you could clone your project and remove this step from the cloned project. You could add the automatic deployment trigger for the "Machine becomes available for deployment" event group to this cloned project and remove this trigger from the original project. This is probably not a good option for a variety of reasons, but if you have a relatively simple setup it might work for you.

    Regards,
    Tom

  2. 2 Posted by daniel.auger on 13 Oct, 2017 06:08 PM

    daniel.auger's Avatar

    Hi Tom,

    It is good to know for future reference that there is not a way to figure out what triggered the deployment. I do agree with the overall philosophy that it shouldn't matter.

    After reading your reply, I re-read the Automatic Deployment Triggers documentation a few times until scoping / targeting clicked with me. I can indeed solve my issue simply through scoping steps to specific roles.

    Much appreciated, Thanks!

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:

»

Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

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