- Notifications
You must be signed in to change notification settings - Fork90
How to output an access log
Lloyd Brookes edited this pageJul 9, 2017 ·3 revisions
To output traditional web server access logs, use--log.format with any value (typically 'combined', 'dev' or 'tiny'). The format value supplied is passed directly tomorgan.
$ ws --log.format tinyServing at http://mbp.local:8010, http://127.0.0.1:8010, http://192.168.0.100:8010GET / 304 - - 18.937 msGET /index.css 304 - - 24.106 msGET /css/font-awesome.min.css 304 - - 17.563 msGET /component/boxer-profile/boxer-profile.css 304 - - 18.342 msGET /component/boxer-list/boxer-list.css 304 - - 15.894 msGET /component/boxer-list/boxer-list-item.css 304 - - 13.983 msGET /component/bout-list-item/bout-list-item.css 304 - - 13.808 msGET /component/bout-list-item/fight-list-item.css 304 - - 1.957 msGET /page/videos-page.css 304 - - 1.714 msGET /page/video-page.css 304 - - 5.436 msGET /page/boxers-page.css 304 - - 6.774 msGET /component/twitter-summary/twitter-summary.css 304 - - 7.460 msGET /page/article-page.css 304 - - 8.443 msGET /component/org-list/org-list.css 304 - - 8.677 msGET /component/api-view/api-view.css 304 - - 8.663 msGET /node_modules/moment/min/moment.min.js 304 - - 8.369 msGET /node_modules/moment/locale/en-gb.js 304 - - 6.527 msGET /index.bundle.js 304 - - 6.157 msGET /component/boxer-profile/boxer-profile.js 304 - - 7.456 ms
To output a dynamic view showing traffic statistics use--log.format stats. It looks something like this and updates in real-time:
