Skip to content

Commit

Permalink
chore: add config policies to CLI reference docs (#10118)
Browse files Browse the repository at this point in the history
  • Loading branch information
amandavialva01 authored and thiagodallacqua-hpe committed Oct 28, 2024
1 parent 9ba90ad commit e0e6a3e
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 28 deletions.
7 changes: 6 additions & 1 deletion docs/manage/config-policies.rst
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,11 @@ or CLI.
both the invariant config and constraints for a given scope are updated together. It is not
possible to update only one of these components independently.

.. note::

It is recommended that administrators save their configuration policies for each scope in
separate YAML or JSON files. This provides an easy way to back up and restore policies if needed.

WebUI
=====

Expand Down Expand Up @@ -90,7 +95,7 @@ Administrators can set Config Policies at both the cluster and workspace levels.
CLI
===

Use the following command to manage workspace-level Config Policies via CLI:
Use the following command to manage Config Policies via CLI:

.. code:: bash
Expand Down
47 changes: 24 additions & 23 deletions docs/reference/cli-reference.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,29 +27,30 @@ help documentation. For example, to learn more about individual experiment comma
positional arguments:
command
help show help for this command
auth manage auth
agent (a) manage agents
command (cmd) manage commands
checkpoint (c) manage checkpoints
deploy (d) manage deployments
experiment (e) manage experiments
job (j) manage job
master (m) manage master
model (m) manage models
notebook manage notebooks
oauth manage OAuth
preview-search preview search
resources (res) query historical resource allocation
shell manage shells
slot (s) manage slots
task manage tasks (commands, experiments, notebooks,
shells, tensorboards)
template (tpl) manage config templates
tensorboard manage TensorBoard instances
trial (t) manage trials
user (u) manage users
version show version information
help show help for this command
auth manage auth
agent (a) manage agents
command (cmd) manage commands
checkpoint (c) manage checkpoints
deploy (d) manage deployments
experiment (e) manage experiments
job (j) manage job
master (m) manage master
model (m) manage models
notebook manage notebooks
oauth manage OAuth
preview-search preview search
resources (res) query historical resource allocation
shell manage shells
slot (s) manage slots
task manage tasks (commands, experiments, notebooks,
shells, tensorboards)
template (tpl) manage config templates
config-policies (cp) manage config policies
tensorboard manage TensorBoard instances
trial (t) manage trials
user (u) manage users
version show version information
optional arguments:
-h, --help show this help message and exit
Expand Down
11 changes: 7 additions & 4 deletions harness/determined/cli/config_policies.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ def delete_config_policies(args: argparse.Namespace) -> None:

args_description: cli.ArgsDescription = [
cli.Cmd(
"config-policies",
"config-policies cp",
None,
"manage config policies",
[
Expand All @@ -110,7 +110,8 @@ def delete_config_policies(args: argparse.Namespace) -> None:
"--workspace-name",
type=str,
required=False,
help="apply config policies to workspace",
help="get config policies from this workspace. When not specified, get "
"global config policies",
),
cli.Group(cli.output_format_args["json"], cli.output_format_args["yaml"]),
],
Expand Down Expand Up @@ -138,7 +139,8 @@ def delete_config_policies(args: argparse.Namespace) -> None:
"--workspace-name",
type=str,
required=False,
help="apply config policies to this workspace",
help="apply config policies to this workspace. When not specified, apply "
"global config policies",
),
],
),
Expand All @@ -158,7 +160,8 @@ def delete_config_policies(args: argparse.Namespace) -> None:
"--workspace-name",
type=str,
required=False,
help="apply config policies to workspace",
help="delete config policies from this workspace. When not specified, "
"delete global config policies",
),
],
),
Expand Down

0 comments on commit e0e6a3e

Please sign in to comment.