forked from uncloud/uncloud
Fix another UndefinedValueError: VM_DIR
decouple.UndefinedValueError: VM_DIR not found. Declare it as envvar or define a default value.
This commit is contained in:
parent
9ae75f20e8
commit
2244b94fd8
1 changed files with 2 additions and 2 deletions
|
@ -33,8 +33,8 @@ running_vms = []
|
||||||
|
|
||||||
__storage_backend = env_vars.get("STORAGE_BACKEND", "filesystem")
|
__storage_backend = env_vars.get("STORAGE_BACKEND", "filesystem")
|
||||||
if __storage_backend == "filesystem":
|
if __storage_backend == "filesystem":
|
||||||
image_storage_handler = FileSystemBasedImageStorageHandler(vm_base=env_vars.get("VM_DIR"),
|
image_storage_handler = FileSystemBasedImageStorageHandler(vm_base=env_vars.get("VM_DIR", "/tmp/ucloud-vms"),
|
||||||
image_base=env_vars.get("IMAGE_DIR"))
|
image_base=env_vars.get("IMAGE_DIR", "/tmp/ucloud-images"))
|
||||||
elif __storage_backend == "ceph":
|
elif __storage_backend == "ceph":
|
||||||
image_storage_handler = CEPHBasedImageStorageHandler(vm_base="ssd", image_base="ssd")
|
image_storage_handler = CEPHBasedImageStorageHandler(vm_base="ssd", image_base="ssd")
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in a new issue