~loggerhead-team/loggerhead/trunk-rich

« back to all changes in this revision

Viewing changes to start-loggerhead.py

  • Committer: Michael Hudson
  • Date: 2008-06-18 04:31:25 UTC
  • Revision ID: michael.hudson@canonical.com-20080618043125-zlm8jjui5xqe4p54
comment out obsolete test

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#!/usr/bin/env python2.4
 
1
#!/usr/bin/env python
2
2
 
3
3
import pkg_resources
4
4
pkg_resources.require("TurboGears")
86
86
    
87
87
    turbogears.update_config(configfile="dev.cfg", modulename="loggerhead.config")
88
88
    
89
 
    potential_overrides = [ ('server.socket_port', int), ('server.webpath', str), ('server.thread_pool', int) ]
 
89
    potential_overrides = [ ('server.socket_port', int), ('server.webpath', str), ('server.thread_pool', int), ('server.socket_host' ,str) ]
90
90
    for key, keytype in potential_overrides:
91
91
        value = config.get(key, None)
92
92
        if value is not None:
110
110
    
111
111
    Root = Root(config)
112
112
    
113
 
    # re-index every 6 hours
114
 
    
115
 
    index_freq = config.get('cache_rebuild_frequency', 6 * 3600)
116
 
    turbogears.scheduler.add_interval_task(initialdelay=1, interval=index_freq, action=Root._check_rebuild)
117
 
    
118
113
    try:
119
114
        turbogears.start_server(Root)
120
115
    finally: