diff options
| author | Mitja Felicijan <mitja.felicijan@gmail.com> | 2021-01-25 21:42:32 +0100 |
|---|---|---|
| committer | Mitja Felicijan <mitja.felicijan@gmail.com> | 2021-01-25 21:42:32 +0100 |
| commit | 38dff5c66360454ea1e4c73e8551dd0acb576cc5 (patch) | |
| tree | dcbfbb5c577cbbf3eb260efbac7fb6838d5d5056 /posts/2021-01-25-goaccess.md | |
| parent | 0ddd55dcf153377c8f252558b249b3a4598867fd (diff) | |
| download | mitjafelicijan.com-38dff5c66360454ea1e4c73e8551dd0acb576cc5.tar.gz | |
Added post about goaccess
Diffstat (limited to 'posts/2021-01-25-goaccess.md')
| -rw-r--r-- | posts/2021-01-25-goaccess.md | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/posts/2021-01-25-goaccess.md b/posts/2021-01-25-goaccess.md index 5067519..b5d40e9 100644 --- a/posts/2021-01-25-goaccess.md +++ b/posts/2021-01-25-goaccess.md | |||
| @@ -95,6 +95,14 @@ If you are using Debian like system GoAccess should be available in repository. | |||
| 95 | apt install goaccess | 95 | apt install goaccess |
| 96 | ``` | 96 | ``` |
| 97 | 97 | ||
| 98 | To enable Geo location we also need one additiona thing. | ||
| 99 | |||
| 100 | ``` | ||
| 101 | cd /var/www/html/stats.stats.com | ||
| 102 | wget https://github.com/texnikru/GeoLite2-Database/raw/master/GeoLite2-City.mmdb.gz | ||
| 103 | gunzip GeoLite2-City.mmdb.gz | ||
| 104 | ``` | ||
| 105 | |||
| 98 | Now we create a shell script that will be executed every 10 minutes. | 106 | Now we create a shell script that will be executed every 10 minutes. |
| 99 | 107 | ||
| 100 | ```sh | 108 | ```sh |
| @@ -112,6 +120,7 @@ goaccess \ | |||
| 112 | --log-file=/var/log/nginx/access-all.log \ | 120 | --log-file=/var/log/nginx/access-all.log \ |
| 113 | --log-format=COMBINED \ | 121 | --log-format=COMBINED \ |
| 114 | --exclude-ip=0.0.0.0 \ | 122 | --exclude-ip=0.0.0.0 \ |
| 123 | --geoip-database=/var/www/html/stats.domain.com/GeoLite2-City.mmdb \ | ||
| 115 | --ignore-crawlers \ | 124 | --ignore-crawlers \ |
| 116 | --real-os \ | 125 | --real-os \ |
| 117 | --output=/var/www/html/stats.domain.com/index.html | 126 | --output=/var/www/html/stats.domain.com/index.html |
