Modify temp folder for certs
[sdnc/oam.git] / installation / sdnc / src / main / scripts / installCerts.py
index a2a25d5..a8133d5 100644 (file)
@@ -36,7 +36,7 @@ with open(os.path.join('/opt/opendaylight/data/log', 'installCerts.log'), 'w') a
 log_format = "%(asctime)s - %(name)s - %(levelname)s - %(message)s"
 logging.basicConfig(filename=log_file,level=logging.DEBUG,filemode='w',format=log_format)
 
-Path = os.environ['ODL_CERT_DIR']
+Path = "/tmp"
 
 zipFileList = []
 
@@ -230,10 +230,10 @@ def get_pass(file_name):
 
 
 def cleanup():
-    for file in os.listdir(Path):
-        if os.path.isfile(Path + '/' + file):
-            logging.debug("Cleaning up the file %s", Path + '/'+ file)
-            os.remove(Path + '/'+ file)
+    for file in jks_files:
+        if os.path.isfile(file):
+            logging.debug("Cleaning up the file %s", file)
+            os.remove(file)
 
 
 def jks_to_p12(file, password):