This commit is contained in:
ahmadbilalkhalid 2019-09-07 15:23:12 +05:00
parent dc799bfab1
commit b18dbe2fa8
2 changed files with 6 additions and 2 deletions

View File

@ -17,7 +17,8 @@ def host():
@click.option("--ssh_key_path", required=True, help="For Example, ~/.ssh/id_rsa")
@click.option("--ssh_key_pass", required=True)
@click.option("--etcd_url", required=True)
def setup(path, ssh_username, ssh_key_path, ssh_key_pass, etcd_url):
@click.option("--without_ceph", default=False, type=bool)
def setup(path, ssh_username, ssh_key_path, ssh_key_pass, etcd_url, without_ceph):
os.chdir(path)
repo_name = "ucloud-vm"
@ -34,6 +35,7 @@ def setup(path, ssh_username, ssh_key_path, ssh_key_pass, etcd_url):
f"ssh_pkey={ssh_key_path}\n"
f"ssh_private_key_password={ssh_key_pass}\n"
f"ETCD_URL={etcd_url}\n"
f"WITHOUT_CEPH={without_ceph}\n"
)
f.writelines(content)

View File

@ -13,7 +13,8 @@ def image():
@click.option("--path", required=True)
@click.option("--base_dir", required=True)
@click.option("--etcd_url", required=True)
def setup(path, base_dir, etcd_url):
@click.option("--without_ceph", default=False, type=bool)
def setup(path, base_dir, etcd_url, without_ceph):
os.chdir(path)
repo_name = "ucloud-image-scanner"
@ -28,6 +29,7 @@ def setup(path, base_dir, etcd_url):
content = (
f"BASE_DIR={base_dir}\n"
f"ETCD_URL={etcd_url}\n"
f"WITHOUT_CEPH={without_ceph}"
)
f.writelines(content)