diff --git a/.github/workflows/deploy-pages.yml b/.github/workflows/deploy-pages.yml index 88d4fb614..528b359c8 100644 --- a/.github/workflows/deploy-pages.yml +++ b/.github/workflows/deploy-pages.yml @@ -22,53 +22,6 @@ defaults: shell: bash jobs: -<<<<<<< HEAD -======= - # Pulls the output.json from the latest successful run of the gateway-conformance.yml workflow - # and stores these as an artifacts for the build job. - pull-outputs: - runs-on: "ubuntu-latest" - strategy: - matrix: - target: ["ipfs/kubo", "ipfs/boxo", "ipfs/bifrost-gateway"] - fail-fast: false - defaults: - run: - shell: bash - steps: - - name: get repo details - id: get-details - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - OWNER_AND_REPO: ${{ matrix.target }} - run: | - DETAILS=$(gh api repos/${OWNER_AND_REPO}) - - DEFAULT_BRANCH=$(echo $DETAILS | jq -r '.default_branch') - echo "default-branch=${DEFAULT_BRANCH}" >> $GITHUB_OUTPUT - - NAME=$(echo $DETAILS | jq -r '.name') - echo "name=${NAME}" >> $GITHUB_OUTPUT - - name: Download json output - id: download-artifact - uses: dawidd6/action-download-artifact@268677152d06ba59fcec7a7f0b5d961b6ccd7e1e # v2.28.0 - with: - workflow: gateway-conformance.yml - workflow_conclusion: "completed" # TODO: ideally we could request success|failure (https://github.com/dawidd6/action-download-artifact#usage) - github_token: ${{ secrets.GITHUB_TOKEN }} - branch: ${{ steps.get-details.outputs.default-branch }} - name: gateway-conformance.json - repo: ${{ matrix.target }} - if_no_artifact_found: fail - allow-forks: false - - name: Upload JSON output - if: (failure() || success()) - uses: actions/upload-artifact@v3 - with: - name: conformance-${{ steps.get-details.outputs.name }}.json - path: ./output.json - # https://github.com/actions/starter-workflows/blob/4a8f18e34dd13d2b6ee4d8da2ba72629eafe1609/pages/hugo.yml#L1 ->>>>>>> b7deea7b (fix: prevent forks) build: runs-on: ubuntu-latest env: diff --git a/README.md b/README.md index f999cd633..326fb54d1 100644 --- a/README.md +++ b/README.md @@ -3,9 +3,7 @@ > A tool designed to test if an IPFS Gateway implementation complies with the [IPFS Gateway Specification](https://specs.ipfs.tech/http-gateways/) correctly. > Distributed as a Docker image, as well as a GitHub Action(s). -- [Implementation Dashboard](#implementation-dashboard) - - [How it Works](#how-it-works) - - [Adding Your Implementation](#adding-your-implementation) +- [Dashboard](#dashboard) - [Commands](#commands) - [`test`](#test) - [Inputs](#inputs) @@ -20,28 +18,41 @@ - [Local Development](#local-development) - [Examples](#examples) - [APIs](#apis) -- [Dashboard](#dashboard) - - [Adding your gateway to the dashboard](#adding-your-gateway-to-the-dashboard) - - [Building the Dashboard](#building-the-dashboard) - [FAQ](#faq) - [In Development](#in-development) -## Implementation Dashboard +## Dashboard -The [Implementation Dashboard](https://ipfs.github.io/gateway-conformance/) is a view that showcases different implementations of IPFS Gateways. It ensures the transparency and clarity of each implementation by utilizing the results from their latest gateway-conformance runs from their Continuous Integration (CI). +The [Implementation Dashboard](https://ipfs.github.io/gateway-conformance/) is a view that showcases different implementations of IPFS Gateways. This dashboard aggregates results from many test runs and renders them on a static website. This'll give you more detailed insights and navigation options. ### How it Works -For every implementations that have been added to the workflow, our dashboard generation workflow loads their most recent `gateway-conformance` test results from their CI. +For every implementations that have been added to the `REPOSITORIES` file, our dashboard generation workflow loads the most recent `gateway-conformance` test results from their CI. You can try this locally with the `make website` command. -### Adding Your Implementation +### Adding your gateway to the dashboard -To include your implementation in the dashboard: +The dashboard is hosted at [conformance.ipfs.tech](https://conformance.ipfs.tech/). It aggregates test outputs from various IPFS implementations and renders them on a static website. -1. Create a Pull Request modifying the file `/.github/workflows/deploy-pages.yml` and append your repository to the list of implementations. -2. Ensure you have a workflow titled "gateway-conformance.yml" in your repository which is responsible for generating the `gateway-conformance.json` artifact. +To add your gateway to the dashboard, you need to: -For reference, you may review other implementations, like Boxo's [here](https://github.com/ipfs/boxo/blob/main/.github/workflows/gateway-conformance.yml). +- Ensure that your gateway's repository is public. +- Ensure your gateway generates generates the `output.json` file in a `gateway-conformance.yml` file. Check [kubo's workflow](https://github.com/ipfs/kubo/blob/master/.github/workflows/gateway-conformance.yml) for an example. +- Add your gateway to the list of repositories in the [REPOSITORIES](./REPOSITORIES) file. + +Once you join the dashboard, your test results will be picked up automatically and your implementation will show up on the dashboard. + +### Building the Dashboard + +- Set up a GitHub Token: Ensure you have a GitHub Token with `repo:read` scope. This is required to download artifacts. +- Run the Build Command: `GH_TOKEN=your_github_token make website` + +This command downloads the latest test artifacts from the repositories listed in the `./REPOSITORIES` file. Then it generates a static website with Hugo in the `www/public` directory. + +### How to work on the Dashboard + +- Use `make website` to generate all the assets required to build the static dashboard +- Use `cd ./www && hugo server` to start a local server with live-reload +- Use `cd ./www/themes/conformance && npm run build` to re-build the theme's styles ## Commands @@ -324,29 +335,6 @@ This templating is used almost everywhere in the test sugar, for example in requ Request().Path("ipfs/{{cid}}", myCid) // will use "ipfs/Qm...." ``` -## Dashboard - -The gateway conformance test suite includes a web dashboard. This dashboard aggregates results from many test runs and renders them on a static website. This'll give you more detailed insights and navigation options. - -### Adding your gateway to the dashboard - -The dashboard is hosted at [conformance.ipfs.tech](https://conformance.ipfs.tech/). It aggregates test outputs from various IPFS implementations and renders them on a static website. - -To add your gateway to the dashboard, you need to: - -- Ensure that your gateway's repository is public. -- Ensure your gateway generates generates the `output.json` file in a `gateway-conformance.yml` file. Check [kubo's workflow](https://github.com/ipfs/kubo/blob/master/.github/workflows/gateway-conformance.yml) for an example. -- Add your gateway to the list of repositories in the [REPOSITORIES](./REPOSITORIES) file. - -Once you join the dashboard, your test results will be picked up automatically and your implementation will show up on the dashboard. - -### Building the Dashboard - -- Set up a GitHub Token: Ensure you have a GitHub Token with `repo:read` scope. This is required to download artifacts. -- Run the Build Command: `GH_TOKEN=your_github_token make website` - -This command downloads the latest test artifacts from the repositories listed in the `./REPOSITORIES` file. Then it generates a static website with Hugo in the `www/public` directory. - ## FAQ ### How to generate XML, HTML and Markdown reports when using the tool as a Docker container? diff --git a/www/content/current.md b/www/content/current.md index c18905c7d..238c9f5ae 100644 --- a/www/content/current.md +++ b/www/content/current.md @@ -1,6 +1,9 @@ --- title: By Reference Implementation published: true +menu: + main: + weight: 10 --- This table shows the test results organized by test groups and reference implementations. Click on any row or cell to drill down into the tests results. diff --git a/www/themes/conformance/layouts/_default/baseof.html b/www/themes/conformance/layouts/_default/baseof.html index 3e101e8ca..167d231c2 100644 --- a/www/themes/conformance/layouts/_default/baseof.html +++ b/www/themes/conformance/layouts/_default/baseof.html @@ -4,8 +4,6 @@ {{- partial "head.html" . -}} - {{- partial "ribbon.html" . -}} - {{- partial "header.html" . -}} diff --git a/www/themes/conformance/layouts/partials/result-table.html b/www/themes/conformance/layouts/partials/result-table.html index 93ab77de2..d04eb75ce 100644 --- a/www/themes/conformance/layouts/partials/result-table.html +++ b/www/themes/conformance/layouts/partials/result-table.html @@ -51,7 +51,6 @@ href="{{ absURL (path.Join "results" $implementation) }}"> {{ $implementation }} - {{ end }} {{ end }} @@ -136,4 +135,4 @@ {{ end }} - \ No newline at end of file + diff --git a/www/themes/conformance/layouts/partials/ribbon.html b/www/themes/conformance/layouts/partials/ribbon.html deleted file mode 100644 index 75c2f4dca..000000000 --- a/www/themes/conformance/layouts/partials/ribbon.html +++ /dev/null @@ -1,70 +0,0 @@ - -Find us on GitHub