Show More
@@ -109,7 +109,7 b' c = get_config()' | |||
|
109 | 109 | # c.PBSControllerLauncher.delete_command = 'qdel' |
|
110 | 110 | |
|
111 | 111 | # A regular expression that takes the output of qsub and find the job id. |
|
112 | # c.PBSControllerLauncher.job_id_regexp = '\d+' | |
|
112 | # c.PBSControllerLauncher.job_id_regexp = r'\d+' | |
|
113 | 113 | |
|
114 | 114 | # The batch submission script used to start the controller. This is where |
|
115 | 115 | # environment variables would be setup, etc. This string is interpolated using |
@@ -129,7 +129,7 b' c = get_config()' | |||
|
129 | 129 | # c.PBSEngineSetLauncher.delete_command = 'qdel' |
|
130 | 130 | |
|
131 | 131 | # A regular expression that takes the output of qsub and find the job id. |
|
132 | # c.PBSEngineSetLauncher.job_id_regexp = '\d+' | |
|
132 | # c.PBSEngineSetLauncher.job_id_regexp = r'\d+' | |
|
133 | 133 | |
|
134 | 134 | # The batch submission script used to start the engines. This is where |
|
135 | 135 | # environment variables would be setup, etc. This string is interpolated using |
@@ -147,7 +147,7 b' c = get_config()' | |||
|
147 | 147 | |
|
148 | 148 | # c.IPControllerJob.job_name = 'IPController' |
|
149 | 149 | # c.IPControllerJob.is_exclusive = False |
|
150 |
# c.IPControllerJob.username = 'USERDOMAIN |
|
|
150 | # c.IPControllerJob.username = r'USERDOMAIN\USERNAME' | |
|
151 | 151 | # c.IPControllerJob.priority = 'Highest' |
|
152 | 152 | # c.IPControllerJob.requested_nodes = '' |
|
153 | 153 | # c.IPControllerJob.project = 'MyProject' |
@@ -163,7 +163,7 b' c = get_config()' | |||
|
163 | 163 | |
|
164 | 164 | # c.IPEngineSetJob.job_name = 'IPEngineSet' |
|
165 | 165 | # c.IPEngineSetJob.is_exclusive = False |
|
166 |
# c.IPEngineSetJob.username = 'USERDOMAIN |
|
|
166 | # c.IPEngineSetJob.username = r'USERDOMAIN\USERNAME' | |
|
167 | 167 | # c.IPEngineSetJob.priority = 'Highest' |
|
168 | 168 | # c.IPEngineSetJob.requested_nodes = '' |
|
169 | 169 | # c.IPEngineSetJob.project = 'MyProject' |
@@ -69,9 +69,7 b' class ClusterDir(Component):' | |||
|
69 | 69 | |
|
70 | 70 | def _location_changed(self, name, old, new): |
|
71 | 71 | if not os.path.isdir(new): |
|
72 |
os.makedirs(new |
|
|
73 | else: | |
|
74 | os.chmod(new, 0777) | |
|
72 | os.makedirs(new) | |
|
75 | 73 | self.security_dir = os.path.join(new, self.security_dir_name) |
|
76 | 74 | self.log_dir = os.path.join(new, self.log_dir_name) |
|
77 | 75 | self.pid_dir = os.path.join(new, self.pid_dir_name) |
@@ -82,9 +80,7 b' class ClusterDir(Component):' | |||
|
82 | 80 | |
|
83 | 81 | def check_log_dir(self): |
|
84 | 82 | if not os.path.isdir(self.log_dir): |
|
85 |
os.mkdir(self.log_dir |
|
|
86 | else: | |
|
87 | os.chmod(self.log_dir, 0777) | |
|
83 | os.mkdir(self.log_dir) | |
|
88 | 84 | |
|
89 | 85 | def _security_dir_changed(self, name, old, new): |
|
90 | 86 | self.check_security_dir() |
@@ -92,7 +88,6 b' class ClusterDir(Component):' | |||
|
92 | 88 | def check_security_dir(self): |
|
93 | 89 | if not os.path.isdir(self.security_dir): |
|
94 | 90 | os.mkdir(self.security_dir, 0700) |
|
95 | else: | |
|
96 | 91 |
|
|
97 | 92 | |
|
98 | 93 | def _pid_dir_changed(self, name, old, new): |
@@ -101,7 +96,6 b' class ClusterDir(Component):' | |||
|
101 | 96 | def check_pid_dir(self): |
|
102 | 97 | if not os.path.isdir(self.pid_dir): |
|
103 | 98 | os.mkdir(self.pid_dir, 0700) |
|
104 | else: | |
|
105 | 99 |
|
|
106 | 100 | |
|
107 | 101 | def check_dirs(self): |
@@ -208,7 +208,7 b' class IPClusterApp(ApplicationWithClusterDir):' | |||
|
208 | 208 | self.auto_create_cluster_dir = True |
|
209 | 209 | super(IPClusterApp, self).find_resources() |
|
210 | 210 | elif subcommand=='start' or subcommand=='stop': |
|
211 |
self.auto_create_cluster_dir = |
|
|
211 | self.auto_create_cluster_dir = True | |
|
212 | 212 | try: |
|
213 | 213 | super(IPClusterApp, self).find_resources() |
|
214 | 214 | except ClusterDirError: |
@@ -257,13 +257,16 b' class IPClusterApp(ApplicationWithClusterDir):' | |||
|
257 | 257 | |
|
258 | 258 | def construct(self): |
|
259 | 259 | config = self.master_config |
|
260 |
|
|
|
261 | pass | |
|
262 |
|
|
|
260 | subcmd = config.Global.subcommand | |
|
261 | reset = config.Global.reset_config | |
|
262 | if subcmd == 'list': | |
|
263 | return | |
|
264 | if subcmd == 'create': | |
|
263 | 265 | self.log.info('Copying default config files to cluster directory ' |
|
264 |
'[overwrite=%r]' % ( |
|
|
265 |
self.cluster_dir_obj.copy_all_config_files(overwrite= |
|
|
266 |
|
|
|
266 | '[overwrite=%r]' % (reset,)) | |
|
267 | self.cluster_dir_obj.copy_all_config_files(overwrite=reset) | |
|
268 | if subcmd =='start': | |
|
269 | self.cluster_dir_obj.copy_all_config_files(overwrite=False) | |
|
267 | 270 | self.start_logging() |
|
268 | 271 | reactor.callWhenRunning(self.start_launchers) |
|
269 | 272 | |
@@ -410,6 +413,7 b' class IPClusterApp(ApplicationWithClusterDir):' | |||
|
410 | 413 | self.log.info( |
|
411 | 414 | 'Starting ipcluster with [daemon=%r]' % config.Global.daemonize |
|
412 | 415 | ) |
|
416 | # TODO: Get daemonize working on Windows or as a Windows Server. | |
|
413 | 417 | if config.Global.daemonize: |
|
414 | 418 | if os.name=='posix': |
|
415 | 419 | daemonize() |
@@ -505,6 +505,7 b' class MPIExecEngineSetLauncher(MPIExecLauncher):' | |||
|
505 | 505 | # SSH launchers |
|
506 | 506 | #----------------------------------------------------------------------------- |
|
507 | 507 | |
|
508 | # TODO: Get SSH Launcher working again. | |
|
508 | 509 | |
|
509 | 510 | class SSHLauncher(BaseLauncher): |
|
510 | 511 | """A minimal launcher for ssh. |
@@ -565,7 +566,7 b' class WindowsHPCLauncher(BaseLauncher):' | |||
|
565 | 566 | |
|
566 | 567 | # A regular expression used to get the job id from the output of the |
|
567 | 568 | # submit_command. |
|
568 | job_id_regexp = Str('\d+', config=True) | |
|
569 | job_id_regexp = Str(r'\d+', config=True) | |
|
569 | 570 | # The filename of the instantiated job script. |
|
570 | 571 | job_file_name = Unicode(u'ipython_job.xml', config=True) |
|
571 | 572 | # The full path to the instantiated job script. This gets made dynamically |
@@ -709,6 +710,7 b' class WindowsHPCEngineSetLauncher(WindowsHPCLauncher):' | |||
|
709 | 710 | # Batch (PBS) system launchers |
|
710 | 711 | #----------------------------------------------------------------------------- |
|
711 | 712 | |
|
713 | # TODO: Get PBS launcher working again. | |
|
712 | 714 | |
|
713 | 715 | class BatchSystemLauncher(BaseLauncher): |
|
714 | 716 | """Launch an external process using a batch system. |
@@ -790,7 +792,7 b' class PBSLauncher(BatchSystemLauncher):' | |||
|
790 | 792 | |
|
791 | 793 | submit_command = Str('qsub', config=True) |
|
792 | 794 | delete_command = Str('qdel', config=True) |
|
793 | job_id_regexp = Str('\d+', config=True) | |
|
795 | job_id_regexp = Str(r'\d+', config=True) | |
|
794 | 796 | batch_template = Str('', config=True) |
|
795 | 797 | batch_file_name = Unicode(u'pbs_batch_script', config=True) |
|
796 | 798 | batch_file = Unicode(u'') |
General Comments 0
You need to be logged in to leave comments.
Login now