This is an automated email from the ASF dual-hosted git repository.

lfrolov pushed a commit to branch DATALAB-2091
in repository https://gitbox.apache.org/repos/asf/incubator-datalab.git


The following commit(s) were added to refs/heads/DATALAB-2091 by this push:
     new dc6f61f  [DATALAB-2091]: changed create_aws_config_files
dc6f61f is described below

commit dc6f61f85dab9d5d70649bb67f2aed5f7949b26d
Author: leonidfrolov <[email protected]>
AuthorDate: Mon Apr 5 16:37:45 2021 +0300

    [DATALAB-2091]: changed create_aws_config_files
---
 infrastructure-provisioning/src/general/lib/aws/actions_lib.py | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/infrastructure-provisioning/src/general/lib/aws/actions_lib.py 
b/infrastructure-provisioning/src/general/lib/aws/actions_lib.py
index 7690a14..bfed3cd 100644
--- a/infrastructure-provisioning/src/general/lib/aws/actions_lib.py
+++ b/infrastructure-provisioning/src/general/lib/aws/actions_lib.py
@@ -1499,8 +1499,8 @@ def get_gitlab_cert(bucket, certfile):
 def create_aws_config_files(generate_full_config=False):
     try:
         aws_user_dir = os.environ['AWS_DIR']
-        logging.info(subprocess.run("rm -rf " + aws_user_dir + " 2>&1", 
capture_output=True, shell=True, check=True))
-        logging.info(subprocess.run("mkdir -p " + aws_user_dir + " 2>&1", 
capture_output=True, shell=True, check=True))
+        subprocess.run("rm -rf " + aws_user_dir + " 2>&1", 
capture_output=True, shell=True, check=True)
+        subprocess.run("mkdir -p " + aws_user_dir + " 2>&1", 
capture_output=True, shell=True, check=True)
 
         with open(aws_user_dir + '/config', 'w') as aws_file:
             aws_file.write("[default]\n")
@@ -1512,8 +1512,8 @@ def create_aws_config_files(generate_full_config=False):
                 aws_file.write("aws_access_key_id = 
{}\n".format(os.environ['aws_access_key']))
                 aws_file.write("aws_secret_access_key = 
{}\n".format(os.environ['aws_secret_access_key']))
 
-        logging.info(subprocess.run("chmod 600 " + aws_user_dir + "/*" + " 
2>&1", capture_output=True, shell=True, check=True))
-        logging.info(subprocess.run("chmod 550 " + aws_user_dir + " 2>&1", 
capture_output=True, shell=True, check=True))
+        subprocess.run("chmod 600 " + aws_user_dir + "/*" + " 2>&1", 
capture_output=True, shell=True, check=True)
+        subprocess.run("chmod 550 " + aws_user_dir + " 2>&1", 
capture_output=True, shell=True, check=True)
         subprocess.run("cat " + aws_user_dir + "/credentials", 
capture_output=True, shell=True, check=True)
         return True
     except Exception as err:

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to