Merge pull request #12 from coder/mes/site-check-script
fix: make site health check easier to use
This commit is contained in:
commit
7d447d1672
23
.env.example
Normal file
23
.env.example
Normal file
@ -0,0 +1,23 @@
|
||||
# ---
|
||||
# These are used for the site health script, run from GitHub Actions. They can
|
||||
# be set manually if you need to run the script locally.
|
||||
|
||||
# Coder admins for Instatus can get this value from https://dashboard.instatus.com/developer
|
||||
export INSTATUS_API_KEY=
|
||||
|
||||
# Can be obtained from calling the Instatus API with a valid token. This value
|
||||
# might not actually need to be private, but better safe than sorry
|
||||
# https://instatus.com/help/api/status-pages
|
||||
export INSTATUS_PAGE_ID=
|
||||
|
||||
# Can be obtained from calling the Instatus API with a valid token. This value
|
||||
# might not actually need to be private, but better safe than sorry
|
||||
# https://instatus.com/help/api/components
|
||||
export INSTATUS_COMPONENT_ID=
|
||||
|
||||
# Can be grabbed from https://vercel.com/codercom/registry/stores/integration/upstash/store_1YDPuBF4Jd0aNpuV/guides
|
||||
# Please make sure that the token you use is KV_REST_API_TOKEN; the script needs
|
||||
# to be able to queries and mutations
|
||||
export VERCEL_API_KEY=
|
||||
|
||||
# ---
|
||||
0
.github/scripts/check_registry_site_health.sh
vendored
Normal file → Executable file
0
.github/scripts/check_registry_site_health.sh
vendored
Normal file → Executable file
23
.github/workflows/check_registry_site_health.yaml
vendored
Normal file
23
.github/workflows/check_registry_site_health.yaml
vendored
Normal file
@ -0,0 +1,23 @@
|
||||
# Check modules health on registry.coder.com
|
||||
name: check-registry-site-health
|
||||
on:
|
||||
schedule:
|
||||
- cron: "0,15,30,45 * * * *" # Runs every 15 minutes
|
||||
workflow_dispatch: # Allows manual triggering of the workflow if needed
|
||||
|
||||
jobs:
|
||||
run-script:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Run check.sh
|
||||
run: |
|
||||
./.github/scripts/check_registry_site_health.sh
|
||||
env:
|
||||
INSTATUS_API_KEY: ${{ secrets.INSTATUS_API_KEY }}
|
||||
INSTATUS_PAGE_ID: ${{ secrets.INSTATUS_PAGE_ID }}
|
||||
INSTATUS_COMPONENT_ID: ${{ secrets.INSTATUS_COMPONENT_ID }}
|
||||
VERCEL_API_KEY: ${{ secrets.VERCEL_API_KEY }}
|
||||
Loading…
x
Reference in New Issue
Block a user