Merge branch 'master' of git.unixpeople.org:hanez/home
This commit is contained in:
commit
0a37530db0
4 changed files with 65 additions and 0 deletions
3
.gitignore
vendored
3
.gitignore
vendored
|
|
@ -3,12 +3,15 @@
|
|||
!bin
|
||||
#!bin/**
|
||||
!bin/eagle.sh
|
||||
!bin/forksync.sh
|
||||
!bin/gnucash.sh
|
||||
!bin/hanez.org.sh
|
||||
!bin/steam.sh
|
||||
!bin/myip.sh
|
||||
!bin/nas-boot.sh
|
||||
!bin/nas-reboot.sh
|
||||
!bin/nas-shutdown.sh
|
||||
!bin/stats.sh
|
||||
|
||||
!.config
|
||||
|
||||
|
|
|
|||
17
bin/forksync.sh
Executable file
17
bin/forksync.sh
Executable file
|
|
@ -0,0 +1,17 @@
|
|||
#!/bin/bash
|
||||
|
||||
#for repo in $(ls /home/hanez/forks | tr '\n' ' '); do
|
||||
for repo in /home/hanez/forks/*; do
|
||||
echo ">>> Updating Fork: $repo"
|
||||
cd $repo
|
||||
|
||||
git fetch upstream
|
||||
|
||||
git checkout master
|
||||
|
||||
git rebase upstream/master
|
||||
#git merge upstream/master
|
||||
|
||||
git push -f origin master
|
||||
done
|
||||
|
||||
7
bin/hanez.org.sh
Executable file
7
bin/hanez.org.sh
Executable file
|
|
@ -0,0 +1,7 @@
|
|||
#!/bin/ash
|
||||
|
||||
export PATH=$HOME/bin:$PATH
|
||||
|
||||
cd /home/hanez/hanez.org
|
||||
|
||||
make server_release
|
||||
38
bin/stats.sh
Executable file
38
bin/stats.sh
Executable file
|
|
@ -0,0 +1,38 @@
|
|||
#!/bin/sh
|
||||
|
||||
output="/var/www/localhost/htdocs/stats/"
|
||||
nic="eth0"
|
||||
|
||||
generate_index() {
|
||||
cat <<-EOF
|
||||
<!doctype html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="cache-control" content=no-cache">
|
||||
<meta http-equiv="refresh" content="3000">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<title>e: eth0 network statistics</title>
|
||||
</head>
|
||||
<body style="background-color:#444">
|
||||
<div style="text-align:center">
|
||||
<div><img src="summary.png" alt="summary"></div>
|
||||
<div><img src="hours.png" alt="hours"></div>
|
||||
<div><img src="days.png" alt="days"></div>
|
||||
<div><img src="months.png" alt="months"></div>
|
||||
<div><img src="top10.png" alt="top10"></div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
EOF
|
||||
}
|
||||
|
||||
if [ ! -f "$output"/index.html ]; then
|
||||
mkdir -p $output
|
||||
generate_index > "$output"/index.html
|
||||
fi
|
||||
|
||||
for type in hours days months top10 summary hsummary vsummary; do
|
||||
vnstati --${type} -i $nic -o $output/${type}.png
|
||||
done
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue