Skip to content

Commit

Permalink
further parsing of allow list
Browse files Browse the repository at this point in the history
  • Loading branch information
Engin Eren committed Jun 23, 2017
1 parent 7d7315c commit 580f8b7
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions Federation/parseAllowList.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
#!/bin/bash

EU=out/list_eu.allow
US=out/list_us.allow

#important domains
#in2p3.fr
#infn.it
#cern.ch
#ac.uk


#awk -F'.' '{\
#if ($2 ~ /-/) print "*."$3"."$4}'

#"${1#*[0-9].[0-9]}"
cat $EU | head -n -2 | awk -F'.' '{
if ($2 ~ /-/ || $2 ~ /[0-9]/ )
print "*."$3"."$4;
else
print "*."$2"."$3"."$4;
}' | sort -u > tmp



echo " " >> tmp
echo "* redirect cms-xrd-transit.cern.ch+:1213" >> tmp

cp tmp out/list_eu_final.allow
rm tmp


exit 0;

0 comments on commit 580f8b7

Please sign in to comment.