diff options
| author | Maurizio Lombardi <mlombard@redhat.com> | 2019-08-19 10:33:06 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-08-19 10:33:06 +0200 |
| commit | a9771b1dd582f3ef99d8bafd8a540ba58d2f63fb (patch) | |
| tree | 986fe024b6660772c31531f4d3de8a212cbdb92e | |
| parent | f601e51182fbb4dab978cf04c94dbd17f4a27a46 (diff) | |
| parent | dc8d9d83cef8489f3b6aec1609299cdba70eda34 (diff) | |
| download | targetcli-a9771b1dd582f3ef99d8bafd8a540ba58d2f63fb.tar.gz | |
Merge pull request #147 from gonzoleeman/fix-discovery_auth-enable
iscsi discovery_auth enable is a number not a string
| -rw-r--r-- | targetcli/ui_target.py | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/targetcli/ui_target.py b/targetcli/ui_target.py index 0c3fe1b..16ccae7 100644 --- a/targetcli/ui_target.py +++ b/targetcli/ui_target.py @@ -34,7 +34,8 @@ from .ui_backstore import complete_path from .ui_node import UINode, UIRTSLibNode auth_params = ('userid', 'password', 'mutual_userid', 'mutual_password') -discovery_params = auth_params + ("enable",) +int_params = ('enable',) +discovery_params = auth_params + int_params class UIFabricModule(UIRTSLibNode): ''' @@ -47,8 +48,12 @@ class UIFabricModule(UIRTSLibNode): self.refresh() if self.rtsnode.has_feature('discovery_auth'): for param in discovery_params: - self.define_config_group_param('discovery_auth', - param, 'string') + if param in int_params: + self.define_config_group_param('discovery_auth', + param, 'number') + else: + self.define_config_group_param('discovery_auth', + param, 'string') self.refresh() # Support late params |
