Skip to content

GitHub Actions

Monitor your CI/CD pipelines to track build duration, catch silent failures, and get alerted on critical workflow breaks.

Add your Pakyas API Key to your repository secrets (Settings > Secrets and variables > Actions):

  • Name: PAKYAS_API_KEY
  • Value: pk_live_...

You can use the pakyas CLI directly in your workflow.

name: Nightly Build
on:
schedule:
- cron: '0 0 * * *'
jobs:
build:
runs-on: ubuntu-latest
env:
PAKYAS_API_KEY: ${{ secrets.PAKYAS_API_KEY }}
steps:
- uses: actions/checkout@v3
- name: Install Pakyas
run: curl -fsSL https://pakyas.com/install.sh | bash
- name: Run Build with Monitoring
run: |
pakyas monitor nightly-build -- npm run build

If you need more granular control (e.g., separating “start” from “success”), you can send raw pings.

steps:
- name: Notify Start
run: pakyas ping nightly-build --start
- name: Run Tests
run: npm test
- name: Notify Success
if: success()
run: pakyas ping nightly-build
- name: Notify Failure
if: failure()
run: pakyas ping nightly-build --fail

Note: The if: always() condition is useful if you want to ensure the final ping sends even if previous steps crash, but usually if: success() and if: failure() pairs covered above are cleaner.