This commit is contained in:
Ahmed Bilal 2019-09-03 18:06:41 +02:00
commit f40d9c3f11
8 changed files with 14 additions and 15 deletions

6
main.py Normal file → Executable file
View file

@ -9,7 +9,7 @@ import logging
from decouple import config
from etcd3_wrapper import Etcd3Wrapper
from config import etcd_client as client
from ucloud_common.vm import VmPool
from ucloud_common.host import HostPool
@ -28,9 +28,7 @@ logging.basicConfig(
def main(vm_prefix, host_prefix, request_prefix):
logging.info(f"{'*' * 5} SESSION STARTED {'*' * 5}")
client = Etcd3Wrapper(
host=config("ETCD_HOST"), port=int(config("ETCD_PORT"))
)
vm_pool = VmPool(client, vm_prefix)
host_pool = HostPool(client, host_prefix)
request_pool = RequestPool(client, request_prefix)