support container_name from cli
Change-Id: Ib3a99b0453d7e04464ffef303accf1b0c05385df
This commit is contained in:
parent
7d3192cdee
commit
0fe85015db
|
@ -117,6 +117,8 @@ if __name__ == '__main__':
|
|||
help='Number of GET operations to perform')
|
||||
parser.add_option('-C', '--num-containers', dest='num_containers',
|
||||
help='Number of containers to distribute objects among')
|
||||
parser.add_option('--container-name', dest='container_name',
|
||||
help='Set the base container_name')
|
||||
parser.add_option('-x', '--no-delete', dest='delete', action='store_false',
|
||||
help='If set, will not delete the objects created')
|
||||
parser.add_option('-V', '--auth_version', dest='auth_version',
|
||||
|
@ -155,8 +157,11 @@ if __name__ == '__main__':
|
|||
options.put_concurrency = options.concurrency
|
||||
options.get_concurrency = options.concurrency
|
||||
options.del_concurrency = options.concurrency
|
||||
options.containers = ['%s_%d' % (options.container_name, i)
|
||||
for i in range(int(options.num_containers))]
|
||||
if options.num_containers == 1:
|
||||
options.containers = [options.container_name]
|
||||
else:
|
||||
options.containers = ['%s_%d' % (options.container_name, i)
|
||||
for i in range(int(options.num_containers))]
|
||||
|
||||
# Turn "yes"/"no"/etc. strings to booleans
|
||||
options.use_proxy = config_true_value(options.use_proxy)
|
||||
|
|
Loading…
Reference in New Issue