mirror of
https://github.com/willnorris/imageproxy.git
synced 2024-12-30 22:34:18 -05:00
update readme to just run imageproxy rather than go run
This commit is contained in:
parent
bf06767283
commit
089ff8925d
1 changed files with 6 additions and 6 deletions
12
README.md
12
README.md
|
@ -127,7 +127,7 @@ you should see a 500px square coder octocat.
|
||||||
By default, the imageproxy command uses an in-memory cache that will grow
|
By default, the imageproxy command uses an in-memory cache that will grow
|
||||||
unbounded. To cache images on disk instead, include the `cacheDir` flag:
|
unbounded. To cache images on disk instead, include the `cacheDir` flag:
|
||||||
|
|
||||||
go run cmd/imageproxy/main.go -cacheDir /tmp/imageproxy
|
imageproxy -cacheDir /tmp/imageproxy
|
||||||
|
|
||||||
Reload the [codercat URL](http://localhost:8080/500/https://octodex.github.com/images/codercat.jpg),
|
Reload the [codercat URL](http://localhost:8080/500/https://octodex.github.com/images/codercat.jpg),
|
||||||
and then inspect the contents of `/tmp/imageproxy`. There should be two files
|
and then inspect the contents of `/tmp/imageproxy`. There should be two files
|
||||||
|
@ -142,17 +142,17 @@ your own hosts to prevent others from abusing it. Of course if you want to
|
||||||
support fetching from any host, leave off the whitelist flag. Try it out by
|
support fetching from any host, leave off the whitelist flag. Try it out by
|
||||||
running:
|
running:
|
||||||
|
|
||||||
go run cmd/imageproxy/main.go -whitelist example.com
|
imageproxy -whitelist example.com
|
||||||
|
|
||||||
Reload the [codercat URL](http://localhost:8080/500/https://octodex.github.com/images/codercat.jpg),
|
Reload the [codercat URL](http://localhost:8080/500/https://octodex.github.com/images/codercat.jpg),
|
||||||
and you should now get an error message. You can specify multiple hosts as a
|
and you should now get an error message. You can specify multiple hosts as a
|
||||||
comma separated list, or prefix a host value with `*.` to allow all sub-domains
|
comma separated list, or prefix a host value with `*.` to allow all sub-domains
|
||||||
as well.
|
as well.
|
||||||
|
|
||||||
Run `go run cmd/imageproxy/main.go -help` for a complete list of flags the
|
Run `imageproxy -help` for a complete list of flags the command accepts. If
|
||||||
command accepts. If you want to use a different caching implementation, it's
|
you want to use a different caching implementation, it's probably easiest to
|
||||||
probably easiest to just make a copy of `cmd/imageproxy/main.go` and customize
|
just make a copy of `cmd/imageproxy/main.go` and customize it to fit your
|
||||||
it to fit your needs... it's a very simple command.
|
needs... it's a very simple command.
|
||||||
|
|
||||||
|
|
||||||
## Deploying ##
|
## Deploying ##
|
||||||
|
|
Loading…
Reference in a new issue