gateway: remote car gateway backend #1486
Workflow file for this run
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: Gateway Conformance | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.event_name == 'push' && github.sha || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
gateway-conformance-car-file: | |
runs-on: ubuntu-latest | |
name: Gateway Conformance (CAR File Gateway) | |
steps: | |
# 1. Download the gateway-conformance fixtures | |
- name: Download gateway-conformance fixtures | |
uses: ipfs/gateway-conformance/.github/actions/[email protected] | |
with: | |
output: fixtures | |
merged: true | |
# 2. Build the gateway binary | |
- name: Setup Go | |
uses: actions/setup-go@v4 | |
with: | |
go-version: 1.21.x | |
- name: Checkout boxo | |
uses: actions/checkout@v4 | |
with: | |
path: boxo | |
- name: Build car-gateway | |
run: go build -o gateway | |
working-directory: boxo/examples/gateway/car-file | |
# 3. Start the gateway binary | |
- name: Start car-gateway | |
run: boxo/examples/gateway/car-file/gateway -c fixtures/fixtures.car -p 8040 & | |
# 4. Run the gateway-conformance tests | |
- name: Run gateway-conformance tests | |
uses: ipfs/gateway-conformance/.github/actions/[email protected] | |
with: | |
gateway-url: http://127.0.0.1:8040 | |
json: output.json | |
xml: output.xml | |
html: output.html | |
markdown: output.md | |
subdomain-url: http://example.net | |
specs: -trustless-ipns-gateway,-path-ipns-gateway,-subdomain-ipns-gateway,-dnslink-gateway | |
args: -skip 'TestGatewayCar/GET_response_for_application/vnd.ipld.car/Header_Content-Length' | |
# 5. Upload the results | |
- name: Upload MD summary | |
if: failure() || success() | |
run: cat output.md >> $GITHUB_STEP_SUMMARY | |
- name: Upload HTML report | |
if: failure() || success() | |
uses: actions/upload-artifact@v3 | |
with: | |
name: gateway-conformance.html | |
path: output.html | |
- name: Upload JSON report | |
if: failure() || success() | |
uses: actions/upload-artifact@v3 | |
with: | |
name: gateway-conformance.json | |
path: output.json | |
gateway-conformance-remote-car: | |
runs-on: ubuntu-latest | |
name: Gateway Conformance (Remote CAR Gateway) | |
steps: | |
# 1. Download the gateway-conformance fixtures | |
- name: Download gateway-conformance fixtures | |
uses: ipfs/gateway-conformance/.github/actions/[email protected] | |
with: | |
output: fixtures | |
merged: true | |
# 2. Build the gateway binaries | |
- name: Setup Go | |
uses: actions/setup-go@v4 | |
with: | |
go-version: 1.21.x | |
- name: Checkout boxo | |
uses: actions/checkout@v4 | |
with: | |
path: boxo | |
- name: Build car-gateway | |
run: go build -o gateway | |
working-directory: boxo/examples/gateway/car-file | |
- name: Build proxy-car-gateway | |
run: go build -o gateway | |
working-directory: boxo/examples/gateway/proxy-car | |
# 3. Start the gateway binaries | |
- name: Start car-gateway | |
run: boxo/examples/gateway/car-file/gateway -c fixtures/fixtures.car -p 8030 & | |
- name: Start proxy-car-gateway | |
run: boxo/examples/gateway/proxy-car/gateway -g http://127.0.0.1:8030 -p 8040 & | |
# 4. Run the gateway-conformance tests | |
- name: Run gateway-conformance tests | |
uses: ipfs/gateway-conformance/.github/actions/[email protected] | |
with: | |
gateway-url: http://127.0.0.1:8040 | |
json: output.json | |
xml: output.xml | |
html: output.html | |
markdown: output.md | |
subdomain-url: http://example.net | |
specs: -trustless-ipns-gateway,-path-ipns-gateway,-subdomain-ipns-gateway,-dnslink-gateway | |
args: -skip 'TestGatewayCar/GET_response_for_application/vnd.ipld.car/Header_Content-Length' | |
# 5. Upload the results | |
- name: Upload MD summary | |
if: failure() || success() | |
run: cat output.md >> $GITHUB_STEP_SUMMARY | |
- name: Upload HTML report | |
if: failure() || success() | |
uses: actions/upload-artifact@v3 | |
with: | |
name: gateway-conformance.html | |
path: output.html | |
- name: Upload JSON report | |
if: failure() || success() | |
uses: actions/upload-artifact@v3 | |
with: | |
name: gateway-conformance.json | |
path: output.json |