| 
                Last change
                  on this file since 577 was
                  398,
                  checked in by andersk, 18 years ago
           | 
        
        
          | 
            Clean up vhosts/ and bring it up to date.
           | 
        
        
          
            
              - 
                  Property svn:executable set to
                  
*
               
             
           | 
        
        | 
            File size:
            400 bytes
           | 
      
      
        
  | Line |   | 
|---|
| 1 | #!/bin/sh | 
|---|
| 2 | cd settings || exit 1 | 
|---|
| 3 | vhosts= | 
|---|
| 4 | check () { | 
|---|
| 5 |     host -t A "$1" | grep -q " has address 18\.181\.0\.46$" && \ | 
|---|
| 6 |         vhosts=$vhosts\ $1 | 
|---|
| 7 | } | 
|---|
| 8 | for i in *; do | 
|---|
| 9 |     check "$i" || echo "warning: $i does not point to scripts!" | 
|---|
| 10 |     check "www.$i" | 
|---|
| 11 |     if echo "$i" | grep -q '\.mit\.edu$'; then | 
|---|
| 12 |         check "$(echo "$i" | sed 's/\.mit\.edu$//')" | 
|---|
| 13 |     fi | 
|---|
| 14 | done | 
|---|
| 15 | echo "ServerName vhosts.mit.edu" | 
|---|
| 16 | echo "ServerAlias$vhosts" | 
|---|
       
      
      Note: See 
TracBrowser
        for help on using the repository browser.