Skip to content
This repository has been archived by the owner on Sep 29, 2023. It is now read-only.

Add pull request deployment statuses for Render.com

License

Notifications You must be signed in to change notification settings

AnandChowdhary/render-deployment-status-action

Repository files navigation

Render Deployment Status Action

build-test

How it works

By default, when Render.com creates a PR environment, it adds a comment to your PR. We use the Render API to add a deployment and update its state.

Screenshot of Render comment and deployment

Note that this action waits until the deployment is completed, so you will be billed for the minutes where it's essentially waiting for the deployment to be completed or errored.

Workflow

Add you Render API key to the Actions secret RENDER_API_KEY and create a worklow .github/workflows/render-deployment-status.yml:

name: Render deployment status

on:
  issue_comment:
    types: [created]

jobs:
  update:
    timeout-minutes: 15
    runs-on: ubuntu-latest
    if: github.event.comment.user.login == 'render[bot]'
    permissions:
      deployments: write

    steps:
      - uses: AnandChowdhary/render-deployment-status-action@main
        with:
          render-api-key: ${{ secrets.RENDER_API_KEY }}
          github-token: ${{ secrets.GITHUB_TOKEN }}

This workflow uses the latest version of this action and runs whenever a comment is made by Render's app. The default GitHub token is used with "write" permission for "deployments".