zhmcclient / zhmccli

A CLI for the IBM Z HMC
Apache License 2.0
10 stars 9 forks source link

Improve "zhmc cpc dpm-import" #605

Closed EdGue42 closed 6 months ago

EdGue42 commented 7 months ago

Describe the bug

Importing a DPM configuration happens as follows:

Past tooling allowed the user to include the to preservation fields directly in the configuration data file; or had the import tool add the fields before passing to the WSAPI endpoint.

The current implementation of zhmc cpc dpm-import doesn't allow for that; as the CLI code will always set the preserve fields (either with True or False); thus overwriting any existing field content originating in the configuration file itself.

Expected behavior

Either: document the current behavior explicitly in the CLI help

Or: improve the CLI implementation to not necessarily overwrite flags already present in the configuration file.

In addition to this, the import command should also provide more information about the configuration that gets applied, to minimize the risk of using it with unwanted configurations.

Environment information

zhmc, version 1.10.1 zhmcclient, version 1.14.0