* fix(ci): add path offset for PR preview subdirectory baseURL When PR preview builds use a subdirectory baseURL like /docs-v2/pr-preview/pr-XXXX/, shortcodes that parse .RelPermalink to detect product context fail because the path has extra segments. This fix: - Adds config/pr-preview/params.yml with prPreviewPathOffset: 3 - Updates workflow to use -e pr-preview environment - Updates api-endpoint, influxdb/host, and children shortcodes to use the offset when indexing path segments - Adds nil-safety with default fallback for placeholder_host Normal builds are unaffected (offset defaults to 0). * fix(ci): add path offset to product-name and sidebar for PR previews Apply the same prPreviewPathOffset fix to product-name.html and sidebar.html that was applied in the initial PR #6665. These templates parse RelPermalink to detect product context, but when baseURL includes a subdirectory path (e.g., /docs-v2/pr-preview/pr-XXXX/), the path indices shift. This fix uses the configurable offset to skip extra path segments in PR preview builds. * fix(ci): skip PR preview for fork PRs and add notice comment Fork PRs cannot deploy to gh-pages because GITHUB_TOKEN has read-only access to the base repository. This is a GitHub security feature. Changes: - Add condition to skip preview job for fork PRs - Add fork-notice job to post helpful comment explaining limitation - Include local preview instructions for contributors |
||
|---|---|---|
| .. | ||
| ISSUE_TEMPLATE | ||
| actions/setup-docs-env | ||
| agents | ||
| instructions | ||
| pull_request_template | ||
| scripts | ||
| workflows | ||
| INSTRUCTIONS.md | ||
| ISSUE_TEMPLATE.md | ||
| PREVIEW_SETUP.md | ||
| PULL_REQUEST_TEMPLATE.md | ||
| SECURITY.md | ||
| copilot-instructions.md | ||