I am using azureml schedules to schedule azureml pipelines. When I want to update a pipeline I am disabling the schedule, deleting and re-publishing the updated pipeline and re-creating the schedule. However every time I do this, the schedule.create command sets the pipeline running as soon as it is published (instead of just setting it to run at the provided recurrence intervals).
Can I disable this behaviour? I dont need the pipeline to automatically run every time I commit and re-run the publish pipelines
Related
I have a Gitlab CI pipeline schedule and noticed that pipelines are not running (anymore).
When starting the schedule manually via the UI (<repo-root>/-/pipeline_schedules) it shows the following
However, there is not pipeline started and no error message is provided.
What can I do in this situation?
The success message is misleading in the sense that one might thing the pipeline was actually created, although it only means that a pipeline was scheduled.
There are various reasons, why a schedule cannot run (anymore).
This can be for example because of conflicting rules or outdated fields in your yml caused by breaking changes due to Gitlab upgrades.
To get to the root of the problem why your pipeline did not run you can trigger a pipeline manually and set the
CI_PIPELINE_SOURCE to hold "schedule" as value.
To do so, go to <repo-root>/-/pipelines/new, set your target branch or tag and the variable as follows
Additionally, you may want to provide further variables required to properly simulate your problematic schedule via the manual run.
Next hit Run pipeline and you should observe an actual error message why the pipeline could not run.
I am trying to rollback in release pipeline when the latest release gets fail it will revert at last successful. I added a PowerShell task which only runs when previous tasks have failed and script which is triggering last successful but the problem is it start redeploying stages randomly not sequentially.## Heading ##
In my scenario I have 3 stages, at the end of each stage, I have added a PowerShell task that will trigger only when the previous task has failed and wrote a script accordingly to trigger last successful release. so it will trigger all the stages in the last release because I haven't got any API or command to trigger release by id. I have an API which triggers only stages. All the stages are queueing sequentially but running randomly.
enter image description here
Since you are using the Release Pipeline, I suggest that you could use Auto-redeploy trigger option for each stage.
When the stage fails, it will re-deploy the last successful release of the current stage.
For example:
Set Auto-redeploy trigger option for stage 2 -> Stage2 fail -> Auto redeploy the last successful Stage 2
Update:
From you requirement, you could try to use the Release Orchestratortask from Release Orchestrator extension. This task could be used to manage the release.
Here is the example:
You could use this task to replace the powershell task. This task supports to select the re-run release name and the target stages.
It can also be sorted according to the input stage order.
Note: you also need to set Maximum number of parallel deployments as 2 for each stage -> Pre-deployment conditions-> Deployment queue settings.
I have set up an Azure pipeline to run GUI tests twice a day. According to the documentation, it should only run if there have been code changes, but it always runs.
This is my cron schedule in "azure-pipelines-cypress.xml"
schedules:
- cron: "0 10 * * *"
displayName: Daily 12:00 build (UTC 10:00)
branches:
include:
- master
Note that the documentation (https://learn.microsoft.com/en-us/azure/devops/pipelines/process/scheduled-triggers?view=azure-devops&tabs=yaml#scheduled-triggers) states:
always: boolean # whether to always run the pipeline or only if there have been source code changes since the last run. The default is false.
Is this simply a bug or am I missing something?
Azure cron pipeline always runs
Update2:
I don't want it to run every time the master branch is updated. It
should run when the master branch is updated AND only at a scheduled
time.
But is that not the expected behavior of my current pipeline? The
current behavior acts as if I had set "always: true"
First of all, thanks Mick for your patience in providing a lot of detailed information.
Now, I figure out the issue and I could reproduce this issue on my side. If we set the scheduled triggers, but the build result is failed. In this case, even if we do not any change, the scheduled triggers will still fire. That because the latest build failed, so the last commit record was not recorded by the pipeline. When the scheduled time is reached, the last commit/source code change still exists. It will trigger scheduled triggers.
So, that the reason why your pipeline still executed, even if you do not do any change in the code/yaml.
If I successfully build the pipeline, the scheduled triggers works as expected.
So, it should be said that the documentation is not clear enough, it should be:
always: boolean # whether to always run the pipeline or only if there
have been source code changes since the last successful run. The
default is false.
I submit this to MS, Thank you for helping us build a better Azure DevOps.
Hope this helps.
Basically I am looking for the retry button for the pipeline triggered, but all I see is a retry button for the individuals jobs of that pipeline. I don't want to have to push a commit just to retry a pipeline.
Reference screenshot
You can retry the latest push on the pipeline by going to:
CI/CD -> Pipelines -> Run Pipeline -> Select the branch to run.
Otherwise, as you've mentioned, you'd have to manually press the retry button for each individual job for the pipeline (for a pipeline that isn't the latest).
GitLab 15.1 (June 2022) should help:
Retry a downstream pipeline from the pipeline graph
Previously, to retry a downstream pipeline, you had to navigate to the pipeline and select retry.
This worked, but was a challenging experience when there were multiple
downstream pipelines.
You had to go into every individual pipeline you
wanted to retry and find the retry option, which was cumbersome.
In this release, we’ve improved the user experience by adding an option to retry downstream pipelines directly from the pipeline graph, without the need to go into each pipeline’s details page.
See Documentation and Issue.>
I've created a new onetime pipeline in Azure Data Factory using Copy Data wizard.
The pipeline has 4 activities and it was run just fine - all 4 activities succeeded.
Now I'd like to rerun the pipeline. So I do:
Clone the pipeline.
Change name to [name]_rev2.
Remove start and end properties.
Deploy the cloned pipeline.
Now the status of the new cloned pipeline is Running.
But no activities are executed at all.
What's wrong?
Mmmmm. Where to start!
In short. You can't just clone the pipeline. If its a one time data factory that you've created it won't have a schedule attached and therefore won't have any time slices provisioned that now require execution.
If your unsure how time slices in ADF work a recommend some reading around this concept.
Next, I recommend opening up a Visual Studio 2015 solution and downloading the data factory that did run as a project. Check out the various JSON blocks for scheduling and interval availability in the datasets, activities and the time frame in the pipeline.
Here's a handy guide for scheduling and execution to understand how to control your pipelines.
https://learn.microsoft.com/en-us/azure/data-factory/data-factory-scheduling-and-execution
Once you've made all the required changes (not just the name) publish the project to a new ADF service.
Hope this helps