diff options
| author | Felix Richter <Felix.Richter@syntax-fehler.de> | 2011-05-29 15:48:47 +0200 | 
|---|---|---|
| committer | Felix Richter <Felix.Richter@syntax-fehler.de> | 2011-05-29 15:48:47 +0200 | 
| commit | 30b44417f91eb100fa67a38e9c1c1f88682c92ef (patch) | |
| tree | f0c6c97d76c9ac7cfe2c88bdffcaee53ff0bc3ae /retiolum/bin/hosts | |
| parent | 427bdf4e2093217f967384f785e3907930a74a21 (diff) | |
| parent | 12c77cdbfa4ec48d935af3ae7cf1118e38bec6e1 (diff) | |
Merge branch 'master' of github.com:krebscode/painload
Diffstat (limited to 'retiolum/bin/hosts')
| -rwxr-xr-x | retiolum/bin/hosts | 11 | 
1 files changed, 11 insertions, 0 deletions
diff --git a/retiolum/bin/hosts b/retiolum/bin/hosts new file mode 100755 index 00000000..6939f52c --- /dev/null +++ b/retiolum/bin/hosts @@ -0,0 +1,11 @@ +#! /bin/sh +set -euf + +netname=${1-retiolum} + +cd /etc/tinc/$netname/hosts + +for i in `ls`; do +  sed -rn 's|^ *Subnet *= *([^ /]*)(/[0-9]*)? *$|\1\t'$i' '$i'.'$netname'|p' $i +done | sort +  | 
