@@ -55,7 +55,6 @@ def waitport(port, prog):
5555 print "Waiting for debug port %d (%s)" % (port , prog )
5656 else :
5757 raise
58- print "All servers running. Hit ^C to kill."
5958 return True
6059
6160def start (race_detection , fakeclock = None ):
@@ -67,11 +66,19 @@ def start(race_detection, fakeclock=None):
6766 """
6867 signal .signal (signal .SIGTERM , lambda _ , __ : stop ())
6968 signal .signal (signal .SIGINT , lambda _ , __ : stop ())
70- global processes
69+ if not install (race_detection ):
70+ return False
7171 # Processes are in order of dependency: Each process should be started
7272 # before any services that intend to send it RPCs. On shutdown they will be
7373 # killed in reverse order.
74- progs = [
74+ progs = []
75+ if default_config_dir .startswith ("test/config-next" ):
76+ # Run the two 'remote' VAs
77+ progs .extend ([
78+ [8011 , 'boulder-va --config %s' % os .path .join (default_config_dir , "va-remote-a.json" )],
79+ [8012 , 'boulder-va --config %s' % os .path .join (default_config_dir , "va-remote-b.json" )],
80+ ])
81+ progs .extend ([
7582 [8003 , 'boulder-sa --config %s' % os .path .join (default_config_dir , "sa.json" )],
7683 [4500 , 'ct-test-srv --config test/ct-test-srv/ct-test-srv.json' ],
7784 [8009 , 'boulder-publisher --config %s' % os .path .join (default_config_dir , "publisher.json" )],
@@ -87,23 +94,17 @@ def start(race_detection, fakeclock=None):
8794 [8002 , 'boulder-ra --config %s' % os .path .join (default_config_dir , "ra.json" )],
8895 [4431 , 'boulder-wfe2 --config %s' % os .path .join (default_config_dir , "wfe2.json" )],
8996 [4000 , 'boulder-wfe --config %s' % os .path .join (default_config_dir , "wfe.json" )],
90- ]
91- if default_config_dir .startswith ("test/config-next" ):
92- # Run the two 'remote' VAs
93- progs .extend ([
94- [8011 , 'boulder-va --config %s' % os .path .join (default_config_dir , "va-remote-a.json" )],
95- [8012 , 'boulder-va --config %s' % os .path .join (default_config_dir , "va-remote-b.json" )],
96- ])
97- if not install (race_detection ):
98- return False
97+ ])
9998 for (port , prog ) in progs :
10099 try :
100+ global processes
101101 processes .append (run (prog , race_detection , fakeclock ))
102102 if not waitport (port , prog ):
103103 return False
104104 except Exception as e :
105105 print (e )
106106 return False
107+ print "All servers running. Hit ^C to kill."
107108 return True
108109
109110def check ():
0 commit comments