GitHub project deployed on Cloudflare pages, can't see deployment status on my GitHub repo.

As the title says, I cant see the deployment status on my github repo as the picture below shows and the cloudflare picture clearly shows that it deployed from the main branch of the repo. Does anyone know how I can see the deployment status on github aswell?
No description
No description
5 Replies
Toasty 🪽
Toasty 🪽•2mo ago
It'll be in the github actions ig
Emil
EmilOP•2mo ago
Yea but how would I get the section? If I deploy through Vercel I get that deployment section.
Cyb3r-Jak3
Cyb3r-Jak3•2mo ago
I am pretty sure Cloudflare doesn't support showing the deployment status when using Pages CI. You would have to build in GitHub Actions using the wrangler action: https://github.com/cloudflare/wrangler-action?tab=readme-ov-file#deploy-your-pages-site-production--preview
Emil
EmilOP•2mo ago
I did as described, created a wrangler actions workflow, pushed it, it successfully deployed but the deployment status is still not visible on the right side of the repository. To clarify what I'm looking for, this is the section I'm talking about:
No description
Emil
EmilOP•2mo ago
Alright I think I figured it out. I had to utilize the GitHub API calls in the workflow itself to update the deployment status. Like this:
- name: Update deployment status to success
if: success()
uses: actions/github-script@v6
with:
script: |
await github.rest.repos.createDeploymentStatus({
owner: context.repo.owner,
repo: context.repo.repo,
deployment_id: "${{ steps.create_deployment.outputs.deployment_id }}",
state: 'success'
});

- name: Update deployment status to failure
if: failure()
uses: actions/github-script@v6
with:
script: |
await github.rest.repos.createDeploymentStatus({
owner: context.repo.owner,
repo: context.repo.repo,
deployment_id: "${{ steps.create_deployment.outputs.deployment_id }}",
state: 'failure'
});
- name: Update deployment status to success
if: success()
uses: actions/github-script@v6
with:
script: |
await github.rest.repos.createDeploymentStatus({
owner: context.repo.owner,
repo: context.repo.repo,
deployment_id: "${{ steps.create_deployment.outputs.deployment_id }}",
state: 'success'
});

- name: Update deployment status to failure
if: failure()
uses: actions/github-script@v6
with:
script: |
await github.rest.repos.createDeploymentStatus({
owner: context.repo.owner,
repo: context.repo.repo,
deployment_id: "${{ steps.create_deployment.outputs.deployment_id }}",
state: 'failure'
});

Did you find this page helpful?