Observatory Github Action
ActionsTags
(2)Run the Mozilla Observatory in CI/CD for any website.
This action is a light wrapper around mozilla/observatory-cli that returns a markdown string.
It can be used in conjunction with other comment based actions to add PR comments.
The github workflows folder contain detailed examples
# examples/workflows/static-url.yml
name: "branch"
on:
pull_request:
jobs:
static-url:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Test Observatory
uses: simonireilly/observatory-github-action@v0.1.3
id: observatory
with:
web_host: https://hungry-borg-990e06.netlify.app
- name: Create commit comment
uses: peter-evans/commit-comment@v1
with:
body: "# Branch PR ${{ steps.observatory.outputs.observatory-report }}"
This method will work for Preview deploys that use the GitHub deployments API. It supports https://vercel.com/ preview Urls.
# examples/workflows/deployment_status.yml
name: "deployment-status"
on:
deployment_status:
jobs:
deployment_status:
runs-on: ubuntu-latest
if: github.event.deployment_status.state == 'success'
steps:
- uses: actions/checkout@v3
- name: Test Observatory
uses: simonireilly/observatory-github-action@v0.1.3
id: observatory
- name: Create commit comment
uses: peter-evans/commit-comment@v1
with:
body: "# Deployment Status _${{ github.event.deployment_status.state }}_ ${{ steps.observatory.outputs.observatory-report }}"
Fork the repository and create a MR against the upstream.
To release, with master branch checked out run:
yarn pub:beta
If this is to be a latest release run:
yarn pub:latest
Keep the changelog up to date between merge releases with:
## [Unchanged]
- HTTP Observatory by April King
- HTTP Observatory CLI by April King
Observatory Github Action is not certified by GitHub. It is provided by a third-party and is governed by separate terms of service, privacy policy, and support documentation.