ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aonis...@apache.org
Subject ambari git commit: AMBARI-14644. CLONE - Ambari creates hdfs user despite ignore_groupsusers_create (aonishuk)
Date Wed, 13 Jan 2016 18:59:20 GMT
Repository: ambari
Updated Branches:
  refs/heads/branch-2.2 a225f394b -> 9e482e380


AMBARI-14644. CLONE - Ambari creates hdfs user despite ignore_groupsusers_create (aonishuk)


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

Branch: refs/heads/branch-2.2
Commit: 9e482e380ab34f748b33d12e9ea0eb0b0f590e4b
Parents: a225f39
Author: Andrew Onishuk <aonishuk@hortonworks.com>
Authored: Wed Jan 13 20:59:14 2016 +0200
Committer: Andrew Onishuk <aonishuk@hortonworks.com>
Committed: Wed Jan 13 20:59:14 2016 +0200

----------------------------------------------------------------------
 .../2.0.6/hooks/before-ANY/scripts/shared_initialization.py   | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/9e482e38/ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-ANY/scripts/shared_initialization.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-ANY/scripts/shared_initialization.py
b/ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-ANY/scripts/shared_initialization.py
index 42b2dd7..10777f9 100644
--- a/ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-ANY/scripts/shared_initialization.py
+++ b/ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-ANY/scripts/shared_initialization.py
@@ -29,8 +29,9 @@ def setup_users():
   Creates users before cluster installation
   """
   import params
+  should_create_users_and_groups = not params.host_sys_prepped and not params.ignore_groupsusers_create
 
-  if not params.host_sys_prepped and not params.ignore_groupsusers_create:
+  if should_create_users_and_groups:
     for group in params.group_list:
       Group(group,
       )
@@ -65,8 +66,10 @@ def setup_users():
 
   if not params.host_sys_prepped:
     if params.has_namenode:
-      create_dfs_cluster_admins()
+      if should_create_users_and_groups:
+        create_dfs_cluster_admins()
     if params.has_tez and params.hdp_stack_version != "" and compare_versions(params.hdp_stack_version,
'2.3') >= 0:
+      if should_create_users_and_groups:
         create_tez_am_view_acls()
   else:
     Logger.info('Skipping setting dfs cluster admin and tez view acls as host is sys prepped')


Mime
View raw message