Refactor workflow concurrency group and consolidate branch validation#207
Draft
Copilot wants to merge 12 commits intomk/dev/change_trigger_branchfrom
Draft
Refactor workflow concurrency group and consolidate branch validation#207Copilot wants to merge 12 commits intomk/dev/change_trigger_branchfrom
Copilot wants to merge 12 commits intomk/dev/change_trigger_branchfrom
Conversation
Signed-off-by: Misha M.-Kupriyanov <kupriyanov@strato.de>
in order to extend it later Signed-off-by: Misha M.-Kupriyanov <kupriyanov@strato.de>
Update trigger-remote-dev-workflow to target the main branch in GitLab for branch types (ionos-dev, ionos-stable). This aligns with the GitLab repository structure where main is the target branch for container image builds. Signed-off-by: Misha M.-Kupriyanov <kupriyanov@strato.de>
Add full CI/CD pipeline support for release candidate (rc/*) branches across all workflow stages: Workflow Triggers: - Add 'rc/**' pattern to push trigger branches - Update concurrency group to prevent rc/* builds from interfering Branch Validation: - Extend configuration check to recognize rc/* as valid trigger branch - Update validation messages to include rc/* in expected patterns Artifactory Integration: - Enable artifact upload for rc/* branches - Create separate 'rc/' directory for rc/* build artifacts - Set ARTIFACTORY_STAGE_PREFIX='rc' for proper organization GitLab Pipeline Integration: - Set BUILD_TYPE='rc' for rc/* branch builds - Update trigger conditions to include rc/* branches - Add rc/* to branch-to-GitLab mapping documentation table This provides complete parity with ionos-dev and ionos-stable branches, enabling proper release candidate workflow with isolated artifacts.
- Pull requests now properly cancel previous runs using explicit PR number - ionos-dev, ionos-stable, and rc/* branches use unique run IDs (no cancellation) - Each production branch build completes independently without cancellation - Other branches continue to use ref-based grouping with cancellation This ensures PR builds are cancelled on new pushes, while production branch builds always complete to avoid losing build artifacts. Signed-off-by: Misha M.-Kupriyanov <kupriyanov@strato.de>
- Add build-artifact to needs array to ensure NC_VERSION output is available - Update if condition to verify both build-artifact and upload-to-artifactory succeeded - Add comprehensive validation step that checks all required variables before triggering remote workflow - Validates secrets (GITLAB_TOKEN, GITLAB_TRIGGER_URL) - Validates job outputs (NC_VERSION, ARTIFACTORY_LAST_BUILD_PATH) - Validates GitHub context variables (sha, run_id, ref_name) - Abort with error if any required variable is missing This prevents the remote workflow from being triggered with missing critical variables like NC_VERSION, which was previously not available because build-artifact was not in the needs array. Signed-off-by: Misha M.-Kupriyanov <kupriyanov@strato.de>
- Change path from flat structure to versioned hierarchy with SHA - For branches: use <stage>/ncw-<ncVersion>/<shortSha>/nextcloud-workspace-<ncVersion>.zip - For PRs: keep simple dev/pr/nextcloud-workspace-pr-<number>.zip - Extract short SHA (first 7 characters) from commit SHA This ensures each build gets a unique path based on both NC version and commit, preventing accidental reuse of artifacts built from different commits with the same version number. Makes it easier to identify and trace artifacts back to their source commit. Signed-off-by: Misha M.-Kupriyanov <kupriyanov@strato.de>
7 tasks
…ch validation Co-authored-by: printminion-co <145785698+printminion-co@users.noreply.github.com>
Co-authored-by: printminion-co <145785698+printminion-co@users.noreply.github.com>
…horing Co-authored-by: printminion-co <145785698+printminion-co@users.noreply.github.com>
…vior Co-authored-by: printminion-co <145785698+printminion-co@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Extend GitHub Actions to support RC branches
Refactor workflow concurrency group and consolidate branch validation
Jan 27, 2026
d3079aa to
d00793e
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Improves GitHub Actions workflow maintainability by refactoring complex branch matching logic into more readable formats and consolidating duplicated validation patterns.
Concurrency group refactoring:
contains(fromJson())for exact branch matching,startsWith()for pattern matchingBranch validation consolidation:
'^(ionos-dev|ionos-stable)$|^rc/.*$'Before:
After:
TODO
Checklist
💡 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.