You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by sm...@apache.org on 2015/05/02 02:12:04 UTC

ambari git commit: AMBARI-10892. Oozie tar extraction and folder set up should be skipped for sys-prepped hosts

Repository: ambari
Updated Branches:
  refs/heads/trunk 0670e953a -> a851dffba


AMBARI-10892. Oozie tar extraction and folder set up should be skipped for sys-prepped hosts


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/a851dffb
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/a851dffb
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/a851dffb

Branch: refs/heads/trunk
Commit: a851dffba329380374c427d8919ec9b595706242
Parents: 0670e95
Author: Sumit Mohanty <sm...@hortonworks.com>
Authored: Fri May 1 15:39:56 2015 -0700
Committer: Sumit Mohanty <sm...@hortonworks.com>
Committed: Fri May 1 15:39:56 2015 -0700

----------------------------------------------------------------------
 .../OOZIE/4.0.0.2.0/package/scripts/oozie.py    | 23 ++++++++++----------
 1 file changed, 12 insertions(+), 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/a851dffb/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie.py b/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie.py
index 21ba06b..77b3cdc 100644
--- a/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie.py
+++ b/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie.py
@@ -192,18 +192,19 @@ def oozie_server_specific():
   Directory(params.oozie_libext_dir,
             recursive=True,
   )
-  
-  configure_cmds = []  
-  configure_cmds.append(('tar','-xvf',format('{oozie_home}/oozie-sharelib.tar.gz'),'-C',params.oozie_home))
-  configure_cmds.append(('cp', params.ext_js_path, params.oozie_libext_dir))
-  configure_cmds.append(('chown', format('{oozie_user}:{user_group}'), format('{oozie_libext_dir}/{ext_js_file}')))
-  configure_cmds.append(('chown', '-RL', format('{oozie_user}:{user_group}'), params.oozie_webapps_conf_dir))
-  
+
   no_op_test = format("ls {pid_file} >/dev/null 2>&1 && ps -p `cat {pid_file}` >/dev/null 2>&1")
-  Execute( configure_cmds,
-    not_if  = no_op_test,
-    sudo = True,
-  )
+  if not params.host_sys_prepped:
+    configure_cmds = []
+    configure_cmds.append(('tar','-xvf',format('{oozie_home}/oozie-sharelib.tar.gz'),'-C',params.oozie_home))
+    configure_cmds.append(('cp', params.ext_js_path, params.oozie_libext_dir))
+    configure_cmds.append(('chown', format('{oozie_user}:{user_group}'), format('{oozie_libext_dir}/{ext_js_file}')))
+    configure_cmds.append(('chown', '-RL', format('{oozie_user}:{user_group}'), params.oozie_webapps_conf_dir))
+
+    Execute( configure_cmds,
+      not_if  = no_op_test,
+      sudo = True,
+    )
 
   if params.jdbc_driver_name=="com.mysql.jdbc.Driver" or \
      params.jdbc_driver_name == "com.microsoft.sqlserver.jdbc.SQLServerDriver" or \