-
Notifications
You must be signed in to change notification settings - Fork 67
Configure nightly release pipeline to run only on schedule and skip when no changes #1706
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
base: develop
Are you sure you want to change the base?
Conversation
@wenytang-ms 👋 This repository doesn't have Copilot instructions. With Copilot instructions, I can understand the repository better, work faster and produce higher quality PRs. I can generate a .github/copilot-instructions.md file for you automatically. Click here to open a pre-filled issue and assign it to me. I'll write the instructions, and then tag you for review. |
- Add schedule with cron '0 3 * * *' to run at 3 AM daily - Add trigger on develop branch for automatic nightly releases on code changes - Ensure release runs 1 hour after build pipeline (2 AM vs 3 AM) - Both schedule and trigger target develop branch for consistency Co-authored-by: wenytang-ms <[email protected]>
@copilot Does this trigger mechanism guarantee that the pipeline will be executed during the current cron interval upon a PR merge or code change? |
No, the trigger mechanism does not wait for the cron interval. With the current configuration: When code is pushed to develop:
Potential Issue:
This means if code is pushed at 10 AM, the release pipeline will try to run immediately but may not find fresh artifacts since the build pipeline only ran at 2 AM. Possible solutions:
Which behavior do you prefer for the nightly release pipeline? |
@copilot please set the pipeline follow 2 rules below
|
Co-authored-by: wenytang-ms <[email protected]>
I've updated the pipeline configuration to follow both rules:
The pipeline will now only run at 3 AM daily and only when there have been code changes, ensuring efficient resource usage and avoiding unnecessary releases. Changes in commit f0916a1. |
This PR configures the Azure Pipeline nightly release to run efficiently by implementing two key behaviors:
always: false
to automatically skip scheduled runs when there are no new commits in the develop branch since the last executionPipeline Configuration
Updated
.azure-pipelines/release/release-nightly.yml
:Coordination with Build Pipeline
The timing remains coordinated with the existing build pipeline:
vscode-gradle-nightly.yml
): Runs at 2 AM and creates artifactsrelease-nightly.yml
): Runs at 3 AM and publishes artifactsThis ensures the build completes before the release pipeline attempts to download and publish artifacts, while avoiding unnecessary releases when no code changes have occurred.
Fixes #1705.
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.