Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ability to accept condition as an input for azure:pipeline:run and output status of the build #31

Open
vsricodes opened this issue Dec 14, 2023 · 1 comment

Comments

@vsricodes
Copy link

The Problem:

The run:azure:pipeline action currently lacks two key functionalities:

Input for condition: This feature is absent, making it impossible to specify a condition that determines whether the action should run the Azure pipeline. This significantly restricts the ability to build complex workflows with conditional execution based on previous steps.
Output for build status: The action does not provide any information about the success or failure of the Azure pipeline run. This absence hinders further decision-making within the workflow, as subsequent steps cannot be controlled based on the pipeline's outcome.
Consequences:

These limitations restrict the potential for creating complex and flexible workflows with the run:azure:pipeline action. This makes it difficult to implement conditional execution and hinders the development of robust and efficient workflows.

Proposed Solutions:

There are two primary solutions to address this issue:

1. Modifying the run:azure:pipeline action:

This solution requires directly altering the action code to introduce the missing input and output features.
Technical expertise in action development and understanding of the Azure DevOps API are necessary for this approach.

2. Utilizing external scripts or actions:

This alternative involves creating a separate script or action responsible for checking the Azure pipeline run status and returning a success/failure flag.
This flag can then be used as a condition for subsequent steps within the workflow.
While requiring additional development effort, this approach offers greater flexibility and avoids modifying the existing action code.
Benefits of Implementation:

Adding input for condition and output for build status would significantly enhance the capabilities of the run:azure:pipeline action:

Enhanced workflow complexity and flexibility: Users can chain multiple pipelines with dependent execution based on previous steps.
Simplified conditional execution: Leveraging the output of the pipeline run, users can easily implement condition-based execution for subsequent steps.
Increased efficiency and automation: Greater control over workflow execution based on pipeline outcomes enables automation of complex tasks and improves efficiency.

@QuadmanSWE
Copy link

Could this solution also cover the fact that in the current state of this plugin we have no way of opting out of waiting for the pipeline run to finish? In one of our templates we create a new repo, an initial run of the pipeline for that repo, and an argocd declaration that we would like the component to run in kubernetes. Once the run finishes it will update which image version to use and the component comes online. The end user creating the new component is not interested in waiting in backstage for the run to finish, it takes a couple of minutes and doesn't actually mean that their service or website is available in the cluster.

It would be preferable for this template to say "kick off this run, and carry on with the last steps of this template meanwhile, as long as it properly started"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants