Versione stampabile1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
| #!/bin/bash
# samu 2010-02-23
STATIC_DEST="/var/www/awstats/static"
cat > "$STATIC_DEST/index.html" << EOF
<html><head><title>AWSTATS - Static</title></head><body>
<h1>AWSTATS - Static Statistics</h1>
<ul>
EOF
for conf in $( ls /etc/awstats/ | grep "^awstats\..*\.conf\$" | sed "s/^awstats\.\(.*\).conf\$/\1/" ); do
echo "Generating static pages for $conf ..."
if [ ! -e "${STATIC_DEST}/${conf}" ]; then
mkdir -p "${STATIC_DEST}/${conf}"
fi
/usr/share/doc/awstats/examples/awstats_buildstaticpages.pl -awstatsprog=/usr/lib/cgi-bin/awstats.pl -dir="${STATIC_DEST}/${conf}" -config="$conf" -buildpdf 2>&1 | sed "s/^/ /"
echo "<li><a href='${conf}/awstats.${conf}.html'>${conf}</a> [<a href='${conf}/awstats.${conf}.pdf'>PDF</a>]</li>" >> "$STATIC_DEST/index.html"
done
cat >> "$STATIC_DEST/index.html" << EOF
</ul>
<hr />
<div><em>Last update: $( date +"%F %T" )</em></div>
</body></html>
EOF |
Bookmark/Search this post with:
re
I will recommend not to wait until you get enough amount of cash to order different goods! You should take the www.lowest-rate-loans.com or credit loan and feel yourself free