-
Notifications
You must be signed in to change notification settings - Fork 88
Conversation
Test: |
@msterin @shaominchen Please review it. |
I think yes. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me and IMO can be merged after CI passing.
Please do reply to my comment, or stop by to discuss)
|
||
def test_tenant_create(self): | ||
args = self.parser.parse_args('tenant create --name=tenant1 --vm-list vm1,vm2'.split()) | ||
args = self.parser.parse_args('vm-group create --name=vm-group1 --vm-list vm1,vm2'.split()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I do not think there was a need to change the names of groups in the test. (no need to roll back though )
self.assertEqual(args.vm_list, ['vm1', 'vm2']) | ||
|
||
def test_tenant_create_missing_option_fails(self): | ||
self.assert_parse_error('tenant create') | ||
self.assert_parse_error('vm-group create') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would be much better to have a global definition and use a VMGROUP name everywhere.
So this line would be self.assert_parse_error(VMGROUP + ' create')
This comment applies to ALL changes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, just a few nits below. Can we file an issue to track the change for VMODL APIs? That can be fixed in future though when we really enable VMODLs.
docs/user-guide/admin-cli.md
Outdated
|
||
Sample: | ||
``` | ||
[root@localhost:~] /usr/lib/vmware/vmdkops/bin/vmdkops_admin.py tenant rm --name=tenant1 --remove-volumes | ||
[root@localhost:~] /usr/lib/vmware/vmdkops/bin/vmdkops_admin.py vm-group rm --name=new-vm-group1 --remove-volumes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: new-vm-group1 => vm-group1
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
docs/user-guide/admin-cli.md
Outdated
564df562-3d58-c99a-e76e-e8792b77ca2d photon4 | ||
564d4728-f1c7-2029-d01e-51f5e6536cd9 photon5 | ||
------------------------------------ -------- | ||
564d5849-b135-1259-cc73-d2d3aa1d9b8c photon-6 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we keep the name consistent? Either photon-6 and photon-7, or photon6 and photon7. Same for other occurrences.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
docs/user-guide/admin-cli.md
Outdated
|
||
Sample: | ||
|
||
```shell | ||
[root@localhost:~] /usr/lib/vmware/vmdkops/bin/vmdkops_admin.py tenant access ls --name=tenant1 | ||
[root@localhost:~] /usr/lib/vmware/vmdkops/bin/vmdkops_admin.py vm-group access ls --name=vm-group1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: remove one redundant space
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
[root@localhost:~] /usr/lib/vmware/vmdkops/bin/vmdkops_admin.py tenant access set --name=tenant1 --datastore=datastore1 --allow-create --volume-maxsize=1000MB --volume-totalsize=2GB | ||
tenant access set succeeded | ||
[root@localhost:~] /usr/lib/vmware/vmdkops/bin/vmdkops_admin.py tenant access ls --name=tenant1 | ||
[root@localhost:~] /usr/lib/vmware/vmdkops/bin/vmdkops_admin.py vm-group access set --name=vm-group1 --datastore=datastore1 --allow-create=True --volume-maxsize=1000MB --volume-totalsize=2GB |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ditto.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
docs/user-guide/faq.md
Outdated
``` | ||
|
||
After this point, the manually upgrade is done, and tenancy operations will succeed. | ||
|
||
#### Case2: Has tenant configured before | ||
#### Case2: Has vm-group configured before |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ditto.
@@ -102,56 +103,64 @@ Step 2: Move the auth-db file at /etc/vmware/vmdkops/auth-db | |||
[root@localhost:/etc/vmware/vmdkops]mv /etc/vmware/vmdkops/auth-db /etc/vmware/vmdkops/auth-db.backup.v10.upgrade | |||
``` | |||
|
|||
Step 3: Verify “tenant ls” command, now only ```_DEFAULT``` should be listed. | |||
Step 3: Verify “vm-group ls” command, now only ```_DEFAULT``` should be listed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ditto.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done.
8ac7e4a
to
954562b
Compare
This PR includes:
Most function name and DB schema remain unchanged.
Currently, "tenant" is still used in logging, I am not sure whether we should change it or not. Any comments?