fix(dnslink-gw): breadcrumbs and CID column when dir listing#7699
Merged
aschmahmann merged 4 commits intomasterfrom Nov 10, 2020
Merged
fix(dnslink-gw): breadcrumbs and CID column when dir listing#7699aschmahmann merged 4 commits intomasterfrom
aschmahmann merged 4 commits intomasterfrom
Conversation
4ea34d8 to
cd1feb3
Compare
4 tasks
This switches go-ipfs to dir-index-html after ipfs/dir-index-html#43 got merged to master
ec164b1 to
c94bd76
Compare
Contributor
|
@lidel Apologies for the delay - v1.2.1 of dir-index-html is here: https://github.com/ipfs/dir-index-html/releases/tag/1.2.1 |
This adds proper end-to-end tests for directory listing on Gateway port that protects us against regressions oni each gw type: - path gateway - subdomain gateway - dnslink website gateway Tests cover: - etag/unicode support - breadcrumbs - file name column - hash column
lidel
commented
Sep 29, 2020
| # | ||
| # Copyright (c) Protocol Labs | ||
|
|
||
| test_description="Test directory listing (dir-index-html) on the HTTP gateway" |
Member
Author
There was a problem hiding this comment.
💭
This file adds proper end-to-end tests for directory listing on Gateway port that protects us against regressions such as ipfs/dir-index-html#42 by testing each gateway type:
- path gateway
- subdomain gateway
- dnslink website gateway
We check behavior of:
- etag/unicode support
- breadcrumbs
- file name column
- hash column
This level of testing is necessary, because URIs will be different on each gw type, and we literally had no tests for this apart from subdomain ones. Now we test all gw types and I can sleep better ;)
8ae153f to
4deaf05
Compare
Member
Author
|
@aschmahmann I believe this is ready for your review. |
aschmahmann
approved these changes
Nov 10, 2020
hacdias
pushed a commit
to ipfs/boxo
that referenced
this pull request
Jan 27, 2023
fix(dnslink-gw): breadcrumbs and CID column when dir listing This commit was moved from ipfs/kubo@499e011
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR aims to solve issue described in ipfs/dir-index-html#42
It changes URI of some broken links when directory listing occurs on DNSLink website adds a bunch of tests.
Changes
There are no visual changes to the way directory listing is presented.
dir-index-htm, this PR is switching to a new release with fix from feat: improved CID column (filename and dnslink support) dir-index-html#43/api/ipfsandą/ś/ć` (utf8)make everything work withX-Ipfs-Gateway-PrefixX-Ipfs-Gateway-Prefixis already mostly broken, filled Removing support for X-Ipfs-Gateway-Prefix #7702 to remove it, so not in the scope of this PRHow to tests this PR
This PR mainly fixes the DNSLink mode, which is when domain passed in
Hostheader has a valid DNSLink record:$ curl -H "Host: dist.ipfs.io" -sD - "http://127.0.0.1:8080/go-ipfs/v0.7.0"It may be tricky to understand what is the fix. The best illustration is to look at CID column:
Hostheader), CID column links to cid.ipfs.io:Similar fix is applied to breadcrumbs, but we link to domain from dnslink instead of a public gateway.