Commit e4459c27 authored by Ioannis Tsafaras's avatar Ioannis Tsafaras

Fixed some imports and paths

parent 861e46d5
...@@ -105,17 +105,10 @@ if __name__ == "__main__": ...@@ -105,17 +105,10 @@ if __name__ == "__main__":
manager = Manager(response) manager = Manager(response)
manager.create_inventory() manager.create_inventory()
# manager.run_playbook(playbook_file="../../ansible/playbooks/testinventory.yml", tags=['hosts']) # manager.run_playbook(playbook_file=script_path + "/../../ansible/playbooks/testinventory.yml", tags=['hosts'])
# manager.run_playbook(playbook_file="../../ansible/playbooks/testproxy.yml", tags=['install']) # manager.run_playbook(playbook_file=script_path + "/../../ansible/playbooks/testproxy.yml", tags=['install'])
manager.run_playbook(playbook_file="../../ansible/playbooks/wait_for_ssh.yml") manager.run_playbook(playbook_file=script_path + "/../../ansible/playbooks/wait_for_ssh.yml")
# manager.run_playbook(playbook_file="../../ansible/playbooks/common/install.yml", tags=['master']) manager.run_playbook(playbook_file=script_path + "/../../ansible/playbooks/cluster/cluster-install.yml")
# manager.run_playbook(playbook_file="../../ansible/playbooks/proxy/proxy.yml")
# manager.run_playbook(playbook_file="../../ansible/playbooks/common/install.yml", tags=['slaves'])
# manager.run_playbook(playbook_file="../../ansible/playbooks/apache-hadoop/hadoop-install.yml")
# manager.run_playbook(playbook_file="../../ansible/playbooks/apache-flink/flink-install.yml")
# manager.run_playbook(playbook_file="../../ansible/playbooks/apache-kafka/kafka-install.yml")
manager.run_playbook(playbook_file="../../ansible/playbooks/cluster/cluster-install.yml")
manager.cleanup() manager.cleanup()
import argparse import argparse
import time import time
from provisioner import Provisioner import os
from ansible_manager import Manager import inspect
from fokia.provisioner import Provisioner
from fokia.ansible_manager import Manager
if __name__ == "__main__": if __name__ == "__main__":
start_time = time.time() start_time = time.time()
script_path = os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe())))
parser = argparse.ArgumentParser(description="Okeanos VM provisioning") parser = argparse.ArgumentParser(description="Okeanos VM provisioning")
parser.add_argument('--cloud', type=str, dest="cloud", default="lambda") parser.add_argument('--cloud', type=str, dest="cloud", default="lambda")
...@@ -54,18 +57,11 @@ if __name__ == "__main__": ...@@ -54,18 +57,11 @@ if __name__ == "__main__":
manager = Manager(provisioner_response) manager = Manager(provisioner_response)
manager.create_inventory() manager.create_inventory()
# manager.run_playbook(playbook_file="../../ansible/playbooks/testinventory.yml", tags=['hosts']) # manager.run_playbook(playbook_file=script_path + "/../../ansible/playbooks/testinventory.yml", tags=['hosts'])
# manager.run_playbook(playbook_file="../../ansible/playbooks/testproxy.yml", tags=['install']) # manager.run_playbook(playbook_file=script_path + "/../../ansible/playbooks/testproxy.yml", tags=['install'])
manager.run_playbook(playbook_file="../../ansible/playbooks/wait_for_ssh.yml") manager.run_playbook(playbook_file=script_path + "/../../ansible/playbooks/wait_for_ssh.yml")
# manager.run_playbook(playbook_file="../../ansible/playbooks/common/install.yml", tags=['master']) manager.run_playbook(playbook_file=script_path + "/../../ansible/playbooks/cluster/cluster-install.yml")
# manager.run_playbook(playbook_file="../../ansible/playbooks/proxy/proxy.yml")
# manager.run_playbook(playbook_file="../../ansible/playbooks/common/install.yml", tags=['slaves'])
# manager.run_playbook(playbook_file="../../ansible/playbooks/apache-hadoop/hadoop-install.yml")
# manager.run_playbook(playbook_file="../../ansible/playbooks/apache-flink/flink-install.yml")
# manager.run_playbook(playbook_file="../../ansible/playbooks/apache-kafka/kafka-install.yml")
manager.run_playbook(playbook_file="../../ansible/playbooks/cluster/cluster-install.yml")
# INSERT PLAYBOOKS HERE # INSERT PLAYBOOKS HERE
......
...@@ -18,7 +18,7 @@ from base64 import b64encode ...@@ -18,7 +18,7 @@ from base64 import b64encode
if not defaults.CACERTS_DEFAULT_PATH: if not defaults.CACERTS_DEFAULT_PATH:
from ssl import get_default_verify_paths from ssl import get_default_verify_paths
CA_CERTS_PATH = get_default_verify_paths().cafile CA_CERTS_PATH = get_default_verify_paths().cafile or get_default_verify_paths().openssl_cafile
if not CA_CERTS_PATH: if not CA_CERTS_PATH:
raise raise
https.patch_with_certs(CA_CERTS_PATH) https.patch_with_certs(CA_CERTS_PATH)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment