mirror of
https://github.com/woodchen-ink/webp_server_go.git
synced 2025-07-18 05:32:02 +08:00
update README.md
This commit is contained in:
parent
4ae6453981
commit
6839c6a7b0
12
README.md
12
README.md
@ -31,16 +31,17 @@ It's basically between `ExpressJS` and `Fiber`, much faster than the `http` pack
|
||||
|
||||
## Usage
|
||||
|
||||
Regarding the `IMG_PATH` section in `config.json`, if you are serving images at `https://example.com/pics/tsuki.jpg` and your files are at `/var/www/image/pics/tsuki.jpg`, then `IMG_PATH` shall be `/var/www/image`.
|
||||
Regarding the `IMG_PATH` section in `config.json`.
|
||||
If you are serving images at `https://example.com/pics/tsuki.jpg` and
|
||||
your files are at `/var/www/image/pics/tsuki.jpg`, then `IMG_PATH` shall be `/var/www/image`.
|
||||
|
||||
1. Edit the `config.json` to face your need, default convert quality is 80%.
|
||||
2. Run the binary like this: `./webp_server`, use `screen` or `tmux` to hold it currently.
|
||||
3. Let Nginx to `proxy_pass http://localhost:3333/;`
|
||||
|
||||
## TODO
|
||||
|
||||
- [] This version doesn't support header-based-output, which means Safari users will not see the converted `webp` images, this should be fixed in later releases.
|
||||
- [] Multi platform support.
|
||||
- [ ] This version doesn't support header-based-output, which means Safari users will not see the converted `webp` images, this should be fixed in later releases.
|
||||
- [ ] Multi platform support.
|
||||
|
||||
## build your own binary
|
||||
Install golang, enable go module, and then...
|
||||
@ -48,4 +49,5 @@ Install golang, enable go module, and then...
|
||||
go get github.com/gofiber/fiber
|
||||
go get github.com/chai2010/webp
|
||||
go build webp_server.go
|
||||
```
|
||||
```
|
||||
**Due to the limitations of webp module, you can't cross compile this tool.**
|
Loading…
x
Reference in New Issue
Block a user