opendal icon indicating copy to clipboard operation
opendal copied to clipboard

Download image when building website may be slow

Open tisonkun opened this issue 3 months ago • 2 comments

https://github.com/apache/opendal/blob/1c771663c4c1fe285075d1a435bae3453cb1af2b/website/plugins/image-ssr-plugin.js#L78-L86

https://github.com/apache/opendal/actions/runs/18396491657/job/52417545045?pr=6640

It takes several minutes to download. Typically, it should be a few seconds.

cc @kingsword09 @Xuanwo

tisonkun avatar Oct 10 '25 04:10 tisonkun

@tisonkun The slowdown isn’t due to image downloads. docusaurus-plugin-llms-builder compiles OpenDAL core’s rustdoc to produce rustdoc-json, and the build time is dominated by that compilation step, not by network fetches.

kingsword09 avatar Oct 11 '25 06:10 kingsword09

It takes several minutes to download. Typically, it should be a few seconds.

This logic exists because ASF Infra does not allow our page to load assets from external sources due to strict content-security-policy settings.

The current settings is:

default-src 'self' data: blob: 'unsafe-inline' 'unsafe-eval' https://www.apachecon.com/ https://www.communityovercode.org/ https://*.apache.org/ https://apache.org/ https://*.scarf.sh/ ; script-src 'self' data: blob: 'unsafe-inline' 'unsafe-eval' https://www.apachecon.com/ https://www.communityovercode.org/ https://*.apache.org/ https://apache.org/ https://*.scarf.sh/ ; style-src 'self' data: blob: 'unsafe-inline' 'unsafe-eval' https://www.apachecon.com/ https://www.communityovercode.org/ https://*.apache.org/ https://apache.org/ https://*.scarf.sh/ ; frame-ancestors 'self'; frame-src 'self' data: blob: 'unsafe-inline' 'unsafe-eval' https://www.apachecon.com/ https://www.communityovercode.org/ https://*.apache.org/ https://apache.org/ https://*.scarf.sh/ ; worker-src 'self' data: blob:;

Xuanwo avatar Oct 12 '25 05:10 Xuanwo