Changeset 779

Show
Ignore:
Timestamp:
09/05/08 12:21:37 (3 months ago)
Author:
free
Message:

Added _Ssl class

Location:
ares/trunk
Files:
2 added
2 modified

Legend:

Unmodified
Added
Removed
  • ares/trunk/ares.py

    r778 r779  
    5555        self.hosts    = _Hosts(self) 
    5656        self.monit    = _Monit(self) 
     57        self.ssl      = _Ssl(self) 
    5758 
    5859if __name__ == '__main__': 
     
    305306        aug.set(cfg + '/startup', '1') 
    306307        aug.set(cfg + '/CHECK_INTERVALS', '30') 
     308 
     309# 
     310# SSL 
     311# 
     312class _Ssl: 
     313 
     314    def __init__(self, ares): 
     315        self._ares = ares 
     316 
     317 
     318    def setup(self): 
     319        # Enable SSL in apache 
     320        dir = 'etc/apache2/mods-enabled' 
     321 
     322        dst = self._ares.root + dir + '/ssl.conf' 
     323        src = '../mods-available/ssl.conf' 
     324        if not os.path.exists(dst): 
     325            os.symlink(src,dst) 
     326 
     327        dst = self._ares.root + dir + '/ssl.load' 
     328        src = '../mods-available/ssl.load' 
     329        if not os.path.exists(dst): 
     330            os.symlink(src,dst) 
  • ares/trunk/tests/TestAres.py

    r777 r779  
    2121        ares.hosts.setup() 
    2222        ares.monit.setup() 
     23        ares.ssl.setup() 
    2324        ares.aug.save() 
    2425