trafficserver-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dra...@apache.org
Subject [trafficserver] 01/02: Fixed an ownership issue in autest
Date Mon, 20 May 2019 19:57:56 GMT
This is an automated email from the ASF dual-hosted git repository.

dragon pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/trafficserver.git

commit b7f33ecdf6cd42ea9053d9a8766fb5a445f1b7ee
Author: Carl Zhang <carl.zhang@verizonmedia.com>
AuthorDate: Fri May 17 16:54:44 2019 -0500

    Fixed an ownership issue in autest
---
 tests/gold_tests/autest-site/trafficserver.test.ext | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)

diff --git a/tests/gold_tests/autest-site/trafficserver.test.ext b/tests/gold_tests/autest-site/trafficserver.test.ext
index ed58fa8..770acbf 100755
--- a/tests/gold_tests/autest-site/trafficserver.test.ext
+++ b/tests/gold_tests/autest-site/trafficserver.test.ext
@@ -76,7 +76,6 @@ def MakeATSProcess(obj, name, command='traffic_server', select_ports=True):
     # set root for this test
     p.Env['TS_ROOT'] = ts_dir
     p.Setup.MakeDir(ts_dir)
-
     # set bin location
 
     p.Env['PROXY_CONFIG_BIN_PATH'] = bin_dir
@@ -89,6 +88,9 @@ def MakeATSProcess(obj, name, command='traffic_server', select_ports=True):
     # copy all basic config files we need to get this to work
     cfg_dir = os.path.join(AUTEST_SITE_PATH, "min_cfg")
 
+    p.Setup.MakeDir(config_dir)
+    p.Setup.Chown(config_dir, "nobody", "root", ignore=True)
+
     for f in os.listdir(cfg_dir):
         p.Setup.CopyAs(os.path.join(cfg_dir, f), config_dir)
 
@@ -121,7 +123,7 @@ def MakeATSProcess(obj, name, command='traffic_server', select_ports=True):
     # create subdirectories that need to exist (but are empty)
     # log directory has to be created with correct permissions
     p.Setup.MakeDir(log_dir)  # log directory has to be created
-    p.Setup.Chown(log_dir, "nobody", "nobody", ignore=True)
+    p.Setup.Chown(log_dir, "nobody", "root", ignore=True)
 
     # set env so traffic server uses correct locations
     p.Env['PROXY_CONFIG_LOG_LOGFILE_DIR'] = log_dir
@@ -136,6 +138,7 @@ def MakeATSProcess(obj, name, command='traffic_server', select_ports=True):
     p.Variables.LOCALSTATEDIR = runtime_dir
 
     p.Setup.MakeDir(runtime_dir)
+    p.Setup.Chown(runtime_dir, "nobody", "root", ignore=True)
     # will need this for traffic_manager is it runs
     p.Setup.MakeDir(os.path.join(config_dir, 'snapshots'))
     p.Env['PROXY_CONFIG_SNAPSHOT_DIR'] = os.path.join(config_dir, 'snapshots')
@@ -143,7 +146,7 @@ def MakeATSProcess(obj, name, command='traffic_server', select_ports=True):
     # create subdirectories that need to exist (but are empty)
     # ssl directory has to be created for keeping certs and keys
     p.Setup.MakeDir(ssl_dir)
-    p.Setup.Chown(ssl_dir, "nobody", "nobody", ignore=True)
+    p.Setup.Chown(ssl_dir, "nobody", "root", ignore=True)
 
     # set env so traffic server uses correct locations
     p.Env['PROXY_CONFIG_SSL_DIR'] = ssl_dir
@@ -152,7 +155,7 @@ def MakeATSProcess(obj, name, command='traffic_server', select_ports=True):
     ########################################################
     # cache.db directory
     p.Setup.MakeDir(storage_dir)
-    p.Setup.Chown(storage_dir, "nobody", "nobody", ignore=True)
+    p.Setup.Chown(storage_dir, "nobody", "root", ignore=True)
     # set env so traffic server uses correct locations
     p.Env['PROXY_CONFIG_STORAGE_DIR'] = storage_dir
     p.Variables.STORAGEDIR = storage_dir


Mime
View raw message