diff options
| author | Minmin Ren <renmm6@chinaunicom.cn> | 2019-05-14 02:42:30 +0000 |
|---|---|---|
| committer | Takashi Kajinami <tkajinam@redhat.com> | 2020-01-21 09:31:57 +0900 |
| commit | 14547dfb1b9aced82d5d333ab329870461034565 (patch) | |
| tree | f773193164e2153f40c4965a24af4a85d0e625d6 /cinderclient/v3 | |
| parent | 44bcd69f5a34905a63c5fa849bcfbee7b73fd56d (diff) | |
| download | python-cinderclient-4.0.3.tar.gz | |
'server_id' is not Attachment attribute, should be
set by 'instance' attribute.
v3/attachments respond body:
{"attachments":
[{"status": "attached",
"instance": INSTANCE_UUID,
"id": ATTACHMENT_UUID,
"volume_id": VOLUME_UUID,
},
...
]
}
Closes-Bug: #1860393
Change-Id: Ica5d278cb7455befe1db4be0ab65114fd606ea0a
(cherry picked from commit 03f228c11e0d88dcc396b30b7544b5cfde894750)
(cherry picked from commit 511224425804621550bf30403f7768eebe6f34ca)
Diffstat (limited to 'cinderclient/v3')
| -rw-r--r-- | cinderclient/v3/shell.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/cinderclient/v3/shell.py b/cinderclient/v3/shell.py index 8cba6ee..7b34691 100644 --- a/cinderclient/v3/shell.py +++ b/cinderclient/v3/shell.py @@ -2093,6 +2093,8 @@ def do_attachment_list(cs, args): marker=args.marker, limit=args.limit, sort=args.sort) + for attachment in attachments: + setattr(attachment, 'server_id', getattr(attachment, 'instance', None)) columns = ['ID', 'Volume ID', 'Status', 'Server ID'] if args.sort: sortby_index = None |
