From e60510228132f426019389659947cfeef020844c Mon Sep 17 00:00:00 2001 From: Steven Armstrong Date: Thu, 13 Oct 2011 15:02:10 +0200 Subject: [PATCH] implement run_code_local Signed-off-by: Steven Armstrong --- lib/cdist/core/code.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib/cdist/core/code.py b/lib/cdist/core/code.py index c42c360b..22a8ad34 100644 --- a/lib/cdist/core/code.py +++ b/lib/cdist/core/code.py @@ -116,6 +116,10 @@ class Code(object): """Run the gencode-remote script for the given cdist object.""" return self._run_gencode(cdist_object, 'remote') + def run_code_local(self, cdist_object): + script = os.path.join(self.local.object_path, cdist_object.code_local_path) + return self.local.run_script(script) + def transfer_code_remote(self, cdist_object): """Transfer the code_remote script for the given object to the remote side.""" source = os.path.join(self.local.object_path, cdist_object.code_remote_path)