Repository navigation
[codex] Improve Bing metadata image crawlability - #3
Draft
RayLi-Muye wants to merge 1 commit into
Draft
RayLi-Muye wants to merge 1 commit into
RayLi-Muye wants to merge 1 commit into
Conversation
This branch has not been deployed
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.
Refs #2
Scope
/api/mediaendpoint so crawlers can fetch metadata assets without an OSS page Referer./api/mediain production with bucket-relative path validation, a stablehttps://mist-arch.com/OSS Referer, and cache headers.robots.txtto allow/api/mediawhile keeping the broader/api/path disallowed.index, followrobots metadata for localized pages.PLAYWRIGHT_PORTso tests can run without stopping unrelated local services on port 3000.Verification
npm run typechecknpm run lintnpm run buildPLAYWRIGHT_PORT=3005 npm run test:e2e— 9 Chromium tests passedgit diff --checkLive/diagnostic proof from the audit:
403 Forbidden, while the same OSS object succeeds when fetched with the production site Referer.Docs Impact
docs/SEO.mddocuments crawler-safe metadata image URLs and the intentional/api/mediarobots allowance.docs/IMAGE_PIPELINE.mddocumentsmediaMetadataUrl()as a metadata-only exception to direct OSS/CDN browser imagery.docs/DEVELOPMENT_LOG.mdrecords the change and verification.Risk / Rollback
/api/mediabecomes publicly reachable for safe bucket-relative OSS paths. The route rejects absolute/data/empty/traversal paths and sends cache headers to limit repeated fetch load./api/mediaas development-only.Owner Decision Needs