mirror of
https://github.com/imgproxy/imgproxy.git
synced 2024-11-24 08:12:38 +02:00
Update changelog and docs
This commit is contained in:
parent
f7dc78a2fe
commit
eb28352a78
@ -2,6 +2,10 @@
|
||||
|
||||
## master
|
||||
|
||||
- New default log format;
|
||||
- `structured` and `json` log formats. Can be set with `IMGPROXY_LOG_FORMAT`;
|
||||
- Better watermarking: image transparency doesn't affect watermarks, faster watermark scaling.
|
||||
|
||||
## v2.4.1
|
||||
|
||||
- More verbose URL parsing errors;
|
||||
|
@ -192,15 +192,22 @@ imgproxy can report occurred errors to Bugsnag, Honeybadger and Sentry:
|
||||
* `IMGPROXY_SENTRY_ENVIRONMENT`: Sentry environment to report to. Default: `production`.
|
||||
* `IMGPROXY_SENTRY_RELEASE`: Sentry release to report to. Default: `imgproxy/{imgproxy version}`.
|
||||
|
||||
### Syslog
|
||||
### Log
|
||||
|
||||
* `IMGPROXY_LOG_FORMAT`: the log format. The following formats are supported:
|
||||
* `pretty`: _(default)_ colored human-readable format;
|
||||
* `structured`: machine-readable format;
|
||||
* `json`: JSON format;
|
||||
|
||||
imgproxy can send logs to syslog, but this feature is disabled by default. To enable it, set `IMGPROXY_SYSLOG_ENABLE` to `true`:
|
||||
|
||||
* `IMGPROXY_SYSLOG_ENABLE`: when `true`, enables sending logs to syslog;
|
||||
* `IMGPROXY_SYSLOG_LEVEL`: maximum log level to send to syslog. Known levels are: `crit`, `error`, `warning` and `notice`. Default: `notice`;
|
||||
* `IMGPROXY_SYSLOG_LEVEL`: maximum log level to send to syslog. Known levels are: `crit`, `error`, `warning` and `info`. Default: `info`;
|
||||
* `IMGPROXY_SYSLOG_NETWORK`: network that will be used to connect to syslog. When blank, the local syslog server will be used. Known networks are `tcp`, `tcp4`, `tcp6`, `udp`, `udp4`, `udp6`, `ip`, `ip4`, `ip6`, `unix`, `unixgram` and `unixpacket`. Default: blank;
|
||||
* `IMGPROXY_SYSLOG_ADDRESS`: address of the syslog service. Not used if `IMGPROXY_SYSLOG_NETWORK` is blank. Default: blank;
|
||||
* `IMGPROXY_SYSLOG_TAG`: specific syslogtag. Default: `imgproxy`;
|
||||
* `IMGPROXY_SYSLOG_TAG`: specific syslog tag. Default: `imgproxy`;
|
||||
|
||||
**Note:** imgproxy always uses structured log format for syslog.
|
||||
|
||||
### Memory usage tweaks
|
||||
|
||||
|
@ -218,7 +218,7 @@ wm:%opacity:%position:%x_offset:%y_offset:%scale
|
||||
|
||||
Puts watermark on the processed image.
|
||||
|
||||
* `opacity` - watermark opacity modifier. Final opacity is calculated like `base_opacity * opacity`. It's highly recommended to set this argument as `1` and adjust opacity with `IMGPROXY_WATERMARK_OPACITY` since this would optimize performance and memory usage.
|
||||
* `opacity` - watermark opacity modifier. Final opacity is calculated like `base_opacity * opacity`.
|
||||
* `position` - (optional) specifies the position of the watermark. Available values:
|
||||
* `ce`: (default) center;
|
||||
* `no`: north (top edge);
|
||||
|
@ -6,12 +6,14 @@ imgproxy supports watermarking processed images with another image.
|
||||
|
||||
There are three ways to specify a watermark image using environment variables:
|
||||
|
||||
* `IMGPROXY_WATERMARK_DATA` - Base64-encoded image data. You can easily calculate it with `base64 tmp/watermark.png | tr -d '\n'`.
|
||||
* `IMGPROXY_WATERMARK_DATA` - Base64-encoded image data. You can easily calculate it with `base64 tmp/watermark.webp | tr -d '\n'`.
|
||||
* `IMGPROXY_WATERMARK_PATH` - path to the locally stored image.
|
||||
* `IMGPROXY_WATERMARK_URL` - watermark image URL.
|
||||
|
||||
You can also specify the base opacity of watermark with `IMGPROXY_WATERMARK_OPACITY`.
|
||||
|
||||
**Note:** If you're going to use `scale` argument of `watermark`, it's highly recommended to use SVG, WebP or JPEG watermarks since these formats support scale-on-load.
|
||||
|
||||
## Watermarking an image
|
||||
|
||||
Watermarks are only available with [advanced URL format](generating_the_url_advanced.md). Use `watermark` processing option to put the watermark on the processed image:
|
||||
@ -23,7 +25,7 @@ wm:%opacity:%position:%x_offset:%y_offset:%scale
|
||||
|
||||
Where arguments are:
|
||||
|
||||
* `opacity` - watermark opacity modifier. Final opacity is calculated like `base_opacity * opacity`. It's highly recommended to set this argument as `1` and adjust opacity with `IMGPROXY_WATERMARK_OPACITY` since this would optimize performance and memory usage.
|
||||
* `opacity` - watermark opacity modifier. Final opacity is calculated like `base_opacity * opacity`.
|
||||
* `position` - (optional) specifies the position of the watermark. Available values:
|
||||
* `ce`: (default) center;
|
||||
* `no`: north (top edge);
|
||||
|
Loading…
Reference in New Issue
Block a user