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-9198. Failing on host re-register (aonishuk)
Date Mon, 19 Jan 2015 17:01:48 GMT
Repository: ambari
Updated Branches:
  refs/heads/trunk 7621f9013 -> 20250f473


AMBARI-9198. Failing on host re-register (aonishuk)


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

Branch: refs/heads/trunk
Commit: 20250f473e30f5c4989291e0033f99ed3f1f4bdd
Parents: 7621f90
Author: Andrew Onishuk <aonishuk@hortonworks.com>
Authored: Mon Jan 19 19:01:39 2015 +0200
Committer: Andrew Onishuk <aonishuk@hortonworks.com>
Committed: Mon Jan 19 19:01:39 2015 +0200

----------------------------------------------------------------------
 ambari-server/src/main/python/bootstrap.py     | 2 +-
 ambari-server/src/test/python/TestBootstrap.py | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/20250f47/ambari-server/src/main/python/bootstrap.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/python/bootstrap.py b/ambari-server/src/main/python/bootstrap.py
index e27f399..8ac6a37 100755
--- a/ambari-server/src/main/python/bootstrap.py
+++ b/ambari-server/src/main/python/bootstrap.py
@@ -243,7 +243,7 @@ class Bootstrap(threading.Thread):
     params = self.shared_state
     user = params.user
 
-    command = "[ -d {0} ] || sudo mkdir -p {0} ; sudo chown {1} {0}".format(self.TEMP_FOLDER,params.user)
+    command = "sudo mkdir -p {0} ; sudo chown -R {1} {0}".format(self.TEMP_FOLDER,params.user)
 
     ssh = SSH(params.user, params.sshkey_file, self.host, command,
               params.bootdir, self.host_log)

http://git-wip-us.apache.org/repos/asf/ambari/blob/20250f47/ambari-server/src/test/python/TestBootstrap.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/test/python/TestBootstrap.py b/ambari-server/src/test/python/TestBootstrap.py
index 0720d8a..373a4be 100644
--- a/ambari-server/src/test/python/TestBootstrap.py
+++ b/ambari-server/src/test/python/TestBootstrap.py
@@ -360,8 +360,8 @@ class TestBootstrap(TestCase):
     self.assertEquals(res, expected)
     command = str(init_mock.call_args[0][3])
     self.assertEqual(command,
-                     "[ -d /var/lib/ambari-agent/data/tmp ] || sudo mkdir -p /var/lib/ambari-agent/data/tmp
; "
-                     "sudo chown root /var/lib/ambari-agent/data/tmp")
+                     "sudo mkdir -p /var/lib/ambari-agent/data/tmp ; "
+                     "sudo chown -R root /var/lib/ambari-agent/data/tmp")
 
   @patch.object(Bootstrap, "getOsCheckScript")
   @patch.object(Bootstrap, "getOsCheckScriptRemoteLocation")


Mime
View raw message