Skip to content

Commit 294c44a

Browse files
authored
Fixed opctl commands. (#269)
2 parents f8de160 + 24078e3 commit 294c44a

File tree

1 file changed

+95
-0
lines changed

1 file changed

+95
-0
lines changed

ads/opctl/cli.py

Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -452,13 +452,51 @@ def init_operator(**kwargs):
452452
@commands.command()
453453
@click.argument("ocid", nargs=1)
454454
@add_options(_model_deployment_options)
455+
@click.option(
456+
"--conda-pack-folder",
457+
required=False,
458+
default=None,
459+
help="folder where conda packs are saved",
460+
)
461+
@click.option(
462+
"--auth",
463+
"-a",
464+
help="authentication method",
465+
type=click.Choice(AuthType.values()),
466+
default=None,
467+
)
468+
@click.option(
469+
"--oci-profile",
470+
help="oci profile",
471+
default=None,
472+
)
473+
@click.option("--debug", "-d", help="set debug mode", is_flag=True, default=False)
455474
def delete(**kwargs):
456475
suppress_traceback(kwargs["debug"])(delete_cmd)(**kwargs)
457476

458477

459478
@commands.command()
460479
@click.argument("ocid", nargs=1)
461480
@add_options(_model_deployment_options)
481+
@click.option(
482+
"--conda-pack-folder",
483+
required=False,
484+
default=None,
485+
help="folder where conda packs are saved",
486+
)
487+
@click.option(
488+
"--auth",
489+
"-a",
490+
help="authentication method",
491+
type=click.Choice(AuthType.values()),
492+
default=None,
493+
)
494+
@click.option(
495+
"--oci-profile",
496+
help="oci profile",
497+
default=None,
498+
)
499+
@click.option("--debug", "-d", help="set debug mode", is_flag=True, default=False)
462500
def cancel(**kwargs):
463501
suppress_traceback(kwargs["debug"])(cancel_cmd)(**kwargs)
464502

@@ -491,6 +529,25 @@ def cancel(**kwargs):
491529
required=False,
492530
default=90
493531
)
532+
@click.option(
533+
"--conda-pack-folder",
534+
required=False,
535+
default=None,
536+
help="folder where conda packs are saved",
537+
)
538+
@click.option(
539+
"--auth",
540+
"-a",
541+
help="authentication method",
542+
type=click.Choice(AuthType.values()),
543+
default=None,
544+
)
545+
@click.option(
546+
"--oci-profile",
547+
help="oci profile",
548+
default=None,
549+
)
550+
@click.option("--debug", "-d", help="set debug mode", is_flag=True, default=False)
494551
def watch(**kwargs):
495552
"""
496553
``tail`` logs form a job run, dataflow run or pipeline run.
@@ -502,6 +559,25 @@ def watch(**kwargs):
502559
@commands.command()
503560
@click.argument("ocid", nargs=1)
504561
@add_options(_model_deployment_options)
562+
@click.option(
563+
"--conda-pack-folder",
564+
required=False,
565+
default=None,
566+
help="folder where conda packs are saved",
567+
)
568+
@click.option(
569+
"--auth",
570+
"-a",
571+
help="authentication method",
572+
type=click.Choice(AuthType.values()),
573+
default=None,
574+
)
575+
@click.option(
576+
"--oci-profile",
577+
help="oci profile",
578+
default=None,
579+
)
580+
@click.option("--debug", "-d", help="set debug mode", is_flag=True, default=False)
505581
def activate(**kwargs):
506582
"""
507583
Activates a data science service.
@@ -512,6 +588,25 @@ def activate(**kwargs):
512588
@commands.command()
513589
@click.argument("ocid", nargs=1)
514590
@add_options(_model_deployment_options)
591+
@click.option(
592+
"--conda-pack-folder",
593+
required=False,
594+
default=None,
595+
help="folder where conda packs are saved",
596+
)
597+
@click.option(
598+
"--auth",
599+
"-a",
600+
help="authentication method",
601+
type=click.Choice(AuthType.values()),
602+
default=None,
603+
)
604+
@click.option(
605+
"--oci-profile",
606+
help="oci profile",
607+
default=None,
608+
)
609+
@click.option("--debug", "-d", help="set debug mode", is_flag=True, default=False)
515610
def deactivate(**kwargs):
516611
"""
517612
Deactivates a data science service.

0 commit comments

Comments
 (0)