Capture any URL in the PMC Wayback Machine #16
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Capture any URL in the PMC Wayback Machine | |
on: | |
workflow_dispatch: | |
inputs: | |
url: | |
required: true | |
secrets: | |
BITBUCKET_READ_ONLY_SSH_KEY: | |
required: false | |
GITHUB_READ_ONLY_SSH_KEY: | |
required: false | |
CHECKLY_API_KEY: | |
required: false | |
CHECKLY_ACCOUNT_ID: | |
required: false | |
permissions: | |
contents: read | |
# See https://www.checklyhq.com/docs/cli/command-line-reference/#npx-checkly-deploy and supporting documentation for | |
# more details on Checkly environment variables. | |
env: | |
CHECKLY_ACCOUNT_ID: ${{ secrets.CHECKLY_ACCOUNT_ID }} | |
CHECKLY_API_KEY: ${{ secrets.CHECKLY_API_KEY }} | |
CHECKLY_REPO_BRANCH: ${{ github.head_ref }} | |
CHECKLY_REPO_COMMIT_OWNER: ${{ github.actor }} | |
CHECKLY_REPO_SHA: ${{ github.sha }} | |
CHECKLY_TEST_ENVIRONMENT: ${{ inputs.QA_SITE_DOMAIN }} | |
FEATURE_BRANCH_NAME: $(echo "${{ github.head_ref || github.ref_name }}" | sed -e 's/feature\/\(.*\)/\1/' | tr '[:upper:]' '[:lower:]') | |
NPM_QAT_SCRIPT: "qat" | |
jobs: | |
checkly-deploy: | |
name: Checkly Run and Deploy | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 # Check out the full git history | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: 20 # Checkly CLI requires Node.js 16 or higher. | |
- name: Restore or cache node_modules # Restore node_modules cache if available | |
id: cache-node-modules | |
uses: actions/cache@v4 | |
with: | |
path: node_modules | |
key: node-modules-${{ hashFiles('package-lock.json') }} | |
- name: Install dependencies # Install NPM dependencies if cache miss | |
if: steps.cache-node-modules.outputs.cache-hit != 'true' | |
run: npm ci | |
- name: Deploy checks # Deploy checks to Checkly for debugging | |
run: npm run qat:checkly:screenshot-url --url=${{github.event.inputs.url}} |