Add compression configuration examples to scripts/run.sh
Type of Change
- [x] Documentation
- [ ] New Feature
- [ ] Bug Fix
- [ ] Performance Improvement
- [ ] Test/CI
- [ ] Refactor
- [ ] Other:
Related Issues
Summary of Changes
Added comprehensive configuration examples for RustFS compression features in scripts/run.sh. Distinguishes between storage-level and HTTP response compression with practical use cases.
Changes Made
-
Clarified compression types: Separated storage-level (
RUSTFS_COMPRESSION_ENABLED) from HTTP response compression (RUSTFS_COMPRESS_*) -
Added 4 practical examples:
- Text files and logs (
.txt,.log,.csv) - JSON/XML API responses
- Web content (HTML, CSS, JavaScript, SVG)
- Large files only (10KB+ threshold)
- Text files and logs (
- Documented whitelist behavior: Extension/MIME matching, error response exclusion, already-encoded detection, size thresholds
-
Fixed typo: Added missing space in
RUSTFS_SKIP_BACKGROUND_TASKcomment
Example Configuration
# Enable HTTP response compression for web content
export RUSTFS_COMPRESS_ENABLE=on
export RUSTFS_COMPRESS_EXTENSIONS=.html,.css,.js,.json,.xml,.txt,.svg
export RUSTFS_COMPRESS_MIME_TYPES=text/*,application/json,application/xml,application/javascript,image/svg+xml
export RUSTFS_COMPRESS_MIN_SIZE=1000
Aligns with whitelist approach documented in docs/compression-best-practices.md and MinIO behavior (compression disabled by default).
Checklist
- [x] I have read and followed the CONTRIBUTING.md guidelines
- [x] Passed
make pre-commit - [x] Added/updated necessary tests
- [x] Documentation updated (if needed)
- [x] CI/CD passed (if applicable)
Impact
- [ ] Breaking change (compatibility)
- [ ] Requires doc/config/deployment update
- [ ] Other impact:
Additional Notes
Script changes only—no code modifications. All examples are commented out by default to preserve existing behavior.
Thank you for your contribution! Please ensure your PR follows the community standards (CODE_OF_CONDUCT.md) and sign the CLA if this is your first contribution.
[!WARNING]
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
dl.rustfs.com
- Triggering command:
/usr/bin/curl curl -s -L REDACTED -o tempfile.zip(dns block)If you need me to access, download, or install something from one of these locations, you can either:
- Configure Actions setup steps to set up my environment, which run before the firewall is enabled
- Add the appropriate URLs or hosts to the custom allowlist in this repository's Copilot coding agent settings (admins only)
Original prompt
å¸®æˆ‘ä¸ºæ–°çš„åŽ‹ç¼©åŠŸèƒ½æ·»åŠ ç¤ºä¾‹åˆ°scripts/run.shä¸
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.