Skip to content

Conversation

@AritraDey-Dev
Copy link
Member

@AritraDey-Dev AritraDey-Dev commented Nov 22, 2025

This PR consolidates docs deployment into a single workflow with automatic PR previews and Github pages deployment.

Fixes #121

/cc @dlebauer

To pass the CI check need to follow step 4 mentioned in the issue i.e.

Once the PR is submitted or ready to submit, the following settings need to be changed by a maintainer
change build and deploy from 'deploy from a branch' to 'GitHub actions' (settings --> pages --> build and deploy)
Make sure the following are enabled
"Read and write permissions" for GITHUB_TOKEN (settings -> actions -> general --> workflow permissions
"Allow GitHub Actions to deploy to GitHub Pages” (settings --> actions --> general --> workflow permissions
Require status check for the job.

Signed-off-by: Aritra Dey <adey01027@gmail.com>
Signed-off-by: Aritra Dey <adey01027@gmail.com>
Copy link
Member

@dlebauer dlebauer left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@AritraDey-Dev thanks for taking on this task, pr-previews will be a useful feature! I have updated the repository settings as indicated.

One change needed - right now the PR preview runs for all PRs, including forks, but the job fails because the action doesn't have permissions to push from the fork.

Please one of the following:

  1. (quickest, no previews from forks) don't allow builds on PRs from forks. This isn't ideal, but changing line 38 to if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository might work
  2. to enable previews from forks we could use a two-step process
    • pull_request workflow just builds sites and uploads it as an artifact
    • a separate script that can be triggered by a maintainer (workflow_dispatch) downloads the artifact and deploys it to a dedicated branch using GITHUB_TOKEN
  3. There may be other and possibly better ways to achieve the pr-previews.

@AritraDey-Dev AritraDey-Dev force-pushed the ci/docs-preview-workflow branch 3 times, most recently from 59d5621 to 797e90c Compare November 25, 2025 09:37
Signed-off-by: Aritra Dey <adey01027@gmail.com>
@AritraDey-Dev AritraDey-Dev force-pushed the ci/docs-preview-workflow branch from 797e90c to 9b6dd7a Compare November 25, 2025 09:46
Signed-off-by: Aritra Dey <adey01027@gmail.com>
Signed-off-by: Aritra Dey <adey01027@gmail.com>
Signed-off-by: Aritra Dey <adey01027@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Automatically preview website on PR

2 participants