diff --git a/ucloud/api/create_image_store.py b/ucloud/api/create_image_store.py index 17fa63c..259b9c8 100755 --- a/ucloud/api/create_image_store.py +++ b/ucloud/api/create_image_store.py @@ -3,7 +3,7 @@ import os from uuid import uuid4 -from ucloud.config import etcd_client, env_vars +from ucloud.config import etcd_client, config data = { "is_public": True, @@ -13,4 +13,4 @@ data = { "attributes": {"list": [], "key": [], "pool": "images"}, } -etcd_client.put(os.path.join(env_vars.get('IMAGE_STORE_PREFIX'), uuid4().hex), json.dumps(data)) +etcd_client.put(os.path.join(config['api']['IMAGE_STORE_PREFIX'], uuid4().hex), json.dumps(data))