Skip to content

ci: restrict scheduled deploy matrix to supported branches#15269

Merged
skjnldsv merged 6 commits into
masterfrom
fix/deploy-supported-branches-only
Jul 2, 2026
Merged

ci: restrict scheduled deploy matrix to supported branches#15269
skjnldsv merged 6 commits into
masterfrom
fix/deploy-supported-branches-only

Conversation

@skjnldsv

@skjnldsv skjnldsv commented Jul 2, 2026

Copy link
Copy Markdown
Member

Follow-up to #15266.
The consolidated deploy matrix iterated every stable* branch incl. long out-of-support ones (stable9–29),
Now builds master + supported stables only (via build/detect-versions.php), and adds a branch workflow_dispatch input to build one branch on demand.

Test run https://github.com/nextcloud/documentation/actions/runs/28593355214/job/84782298571

AI-assisted (ClaudeCode:claude-opus-4-8).

@github-actions github-actions Bot added the github_actions Pull requests that update GitHub Actions code label Jul 2, 2026
@skjnldsv skjnldsv requested a review from miaulalala July 2, 2026 13:23
@skjnldsv skjnldsv self-assigned this Jul 2, 2026
@github-actions

github-actions Bot commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

📖 Documentation Preview

🔍 Open preview →

No RST documentation pages changed in this PR.

Last updated: Thu, 02 Jul 2026 14:40:46 GMT

The consolidated deploy matrix iterated every stable* branch on the remote,
including long out-of-support ones (stable9..stable29). In a single run this
also blows past the 256-jobs-per-run limit and wastes CI on branches that no
longer build.

- prepare now builds master + only the stable branches within the support
  window, reusing build/detect-versions.php for the lowest..highest range.
- workflow_dispatch gains an optional "branch" input to build & deploy a
  single branch on demand (empty = master + all supported stables).

Assisted-by: ClaudeCode:claude-opus-4-8
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
@skjnldsv skjnldsv force-pushed the fix/deploy-supported-branches-only branch from 4bbe00f to a9244d7 Compare July 2, 2026 13:32
skjnldsv added 2 commits July 2, 2026 15:40
The deploy resolves build-docs.yml from master for every matrix leg, so a
hardcoded python-version would build all branches with master's Python. Read
the version from the checked-out branch (.python-version) instead, falling
back to 3.13 when the file is absent, so each version can pin its own Python
even under the shared workflow. requirements.txt only pins packages and
cannot carry the interpreter version.

Assisted-by: ClaudeCode:claude-opus-4-8
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
The redirect step iterated every server/*/ folder on gh-pages, including
ancient versions (server/12) whose legacy layout has go.php as a file, so
mkdir -p failed. Track the folders applied this run in the apply step and
restrict the redirect loop to those, and remove any stale go.php path first.

Assisted-by: ClaudeCode:claude-opus-4-8
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
@skjnldsv skjnldsv mentioned this pull request Jul 2, 2026
skjnldsv added 3 commits July 2, 2026 16:10
Stable branches conf.py derive the display version from GITHUB_BASE_REF /
GITHUB_REF, which in the single-run deploy reflect the workflow branch, not the
matrix leg. Every stable build was therefore mislabelled as the dev version
(e.g. stable32 rendered as "35 / latest"). Expose the built branch via
GITHUB_BASE_REF in the build jobs so each stable conf.py resolves correctly;
master conf.py is unaffected (it uses DOCS_DISPLAY_VERSION).

Assisted-by: ClaudeCode:claude-opus-4-8
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
Add a small table to the deploy PR body showing how many files changed per
version folder, so reviewers can see at a glance what actually got updated.

Assisted-by: ClaudeCode:claude-opus-4-8
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
Overriding the reserved GITHUB_BASE_REF via job env does not reach the build
process (the runner ignores it), so stable builds were still mislabelled.
Instead rely on DOCS_DISPLAY_VERSION, which build-html already exports via
detect-versions and which the epub job now sets too (PDF is covered by
DOCS_RELEASE). Stable branches conf.py must read DOCS_DISPLAY_VERSION for this
to take effect (backported separately).

Assisted-by: ClaudeCode:claude-opus-4-8
Signed-off-by: skjnldsv <skjnldsv@protonmail.com>
@skjnldsv skjnldsv merged commit ff2d332 into master Jul 2, 2026
119 checks passed
@skjnldsv skjnldsv deleted the fix/deploy-supported-branches-only branch July 2, 2026 21:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to review github_actions Pull requests that update GitHub Actions code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants