Skip to content

Update to latest (#92) #308

Update to latest (#92)

Update to latest (#92) #308

Workflow file for this run

name: ci
on:
pull_request: {}
push:
branches: ["main"]
permissions:
pull-requests: write
contents: read
deployments: write
jobs:
tests:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 2
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 22
cache: "npm"
- name: Install
run: make install
- name: Test
run: npm start -- test --cwd ./gateways/hive-gateway --run-script ./run.sh --reporter tap --graphql http://127.0.0.1:4000/graphql --healthcheck http://127.0.0.1:4000/healthcheck --exit-on-fail
gateways:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 2
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 22
cache: "npm"
- name: Prepare
run: make install
- name: Test Gateways
run: make test-all
- name: Summary
run: |
EOF=$(dd if=/dev/urandom bs=15 count=1 status=none | base64)
echo "summary<<$EOF" >> "$GITHUB_ENV"
cat ./REPORT.md >> "$GITHUB_ENV"
echo "$EOF" >> "$GITHUB_ENV"
- name: Publish Summary
uses: marocchino/sticky-pull-request-comment@v2
with:
header: "Test Results"
message: ${{ env.summary }}
deploy:
runs-on: ubuntu-latest
name: Deploy
steps:
- name: checkout
uses: actions/checkout@v4
- name: setup node
uses: actions/setup-node@v4
with:
node-version: 22
cache: "npm"
- name: install
run: npm ci
- name: Publish to Cloudflare Pages
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CF_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: federation-gateway-compatibility
directory: ./website
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.event.pull_request.number != '' && format('pr-{0}', github.event.pull_request.number) || 'main' }}