RemoteRunner has been designed to send scripts/applications and input files on remote worker nodes having no outbound connectivity (e.g. supercomputers)

Mostly called by workflow modules, RemoteRunner is generally the last component to get through before the script/application execution on a remote machine.

class DIRAC.WorkloadManagementSystem.Utilities.RemoteRunner.RemoteRunner(siteName=None, ceName=None, queueName=None)

Bases: object

__init__(siteName=None, ceName=None, queueName=None)
execute(command, workingDirectory='.', numberOfProcessors=1, cleanRemoteJob=True)

Execute the command remotely via a CE

  • command (str) – command to execute remotely

  • workingDirectory (str) – directory containing the inputs required by the command

  • numberOfProcessors (int) – number of processors to allocate to the command

  • cleanRemoteJob (str) – clean the files related to the command on the remote host if True


(status, output, error)


Main method: decides whether the execution will be done locally or remotely via a CE.

This method does not really make sense: if we use RemoteRunner, it means we want to perform a remote execution. Therefore, this should be checked before calling RemoteRunner by checking /LocalSite/RemoteExecution for instance.



Deprecated: Use gConfig.getValue(“/LocalSite/RemoteExecution”, False) instead.