log.format, error reporting
This commit is contained in:
@ -1,13 +1,13 @@
|
||||
# Logging
|
||||
By default, local-web-server outputs a simple, dynamic statistics view. To see traditional web server logs, use `--log-format`:
|
||||
By default, local-web-server outputs a simple, dynamic statistics view. To see traditional web server logs, use `--log.format`:
|
||||
|
||||
```sh
|
||||
$ ws --log-format combined
|
||||
$ ws --log.format combined
|
||||
serving at http://localhost:8000
|
||||
::1 - - [16/Nov/2015:11:16:52 +0000] "GET / HTTP/1.1" 200 12290 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/48.0.2562.0 Safari/537.36"
|
||||
```
|
||||
|
||||
The format value supplied is passed directly to [morgan](https://github.com/expressjs/morgan). The exception is `--log-format none` which disables all output.
|
||||
The format value supplied is passed directly to [morgan](https://github.com/expressjs/morgan). The exception is `--log.format none` which disables all output.
|
||||
|
||||
# Visualisation
|
||||
|
||||
@ -17,7 +17,7 @@ To get live statistics in [goaccess](http://goaccess.io/), first create this con
|
||||
```
|
||||
time-format %T
|
||||
date-format %d/%b/%Y
|
||||
log-format %h %^[%d:%t %^] "%r" %s %b "%R" "%u"
|
||||
log.format %h %^[%d:%t %^] "%r" %s %b "%R" "%u"
|
||||
```
|
||||
|
||||
Then, start the server, outputting `combined` format logs to disk:
|
||||
|
@ -4,7 +4,7 @@ To get live statistics in [goaccess](http://goaccess.io/), first create this con
|
||||
```
|
||||
time-format %T
|
||||
date-format %d/%b/%Y
|
||||
log-format %h %^[%d:%t %^] "%r" %s %b "%R" "%u"
|
||||
log.format %h %^[%d:%t %^] "%r" %s %b "%R" "%u"
|
||||
```
|
||||
|
||||
Then, start the server, outputting `combined` format logs to disk:
|
||||
|
Reference in New Issue
Block a user