This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env python3 | |
| """ | |
| apache_insights.py — Quick, practical insights from Apache/Nginx combined logs. | |
| Features | |
| - Parses (gz or plain) Combined Log Format lines like: | |
| 66.249.72.225 - - [24/Oct/2025:00:01:22 +0000] "GET /path HTTP/1.1" 200 123 "-" "UA" | |
| - Summaries: | |
| * Requests/time (minute & hour), spike detection | |
| * Status code distribution & 3xx/4xx/5xx leaders |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var gulp = require('gulp'), | |
| gutil = require('gulp-util'), | |
| sass = require('gulp-sass'), | |
| csso = require('gulp-csso'), | |
| uglify = require('gulp-uglify'), | |
| jade = require('gulp-jade'), | |
| concat = require('gulp-concat'), | |
| livereload = require('gulp-livereload'), // Livereload plugin needed: https://chrome.google.com/webstore/detail/livereload/jnihajbhpnppcggbcgedagnkighmdlei | |
| tinylr = require('tiny-lr'), | |
| express = require('express'), |