Add baseURL configuration option to S3 modules by WakuwakuP · Pull Request #1876 · hackmdio/codimd
Pull Request Overview
This PR adds a new configuration option, s3.baseURL, to allow replacing the default S3 endpoint with a custom domain for image distribution (e.g. via a CDN).
- Updated the image upload logic in lib/imageRouter/s3.js to use baseURL when provided.
- Extended configuration files (environment.js and default.js) to expose baseURL as an option.
Reviewed Changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| lib/imageRouter/s3.js | Updated uploadImage to use s3.baseURL if set |
| lib/config/environment.js | Added baseURL from environment variables |
| lib/config/default.js | Added baseURL with an undefined default |