# Copyright 2015 PerfKitBenchmarker Authors. All rights reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#   http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

from perfkitbenchmarker import flags

flags.DEFINE_string('rack_path',
                    default='rack',
                    help='The path for the rack CLI binary.')

flags.DEFINE_string('region', default='IAD',
                    help='A string indicating which Rackspace region to use.')

flags.DEFINE_string('profile', default=None,
                    help='A string indicating which RackCLI profile to use. '
                         'If none is specified default profile is used '
                         '(see https://developer.rackspace.com/docs/'
                         'rack-cli/configuration/#config-file)')

flags.DEFINE_boolean('boot_from_cbs_volume', 'False',
                     'When flag is included the instance will use a remote disk'
                     ' as its boot disk, if machine_type supports it'
                     ' (Currently Standard and OnMetal flavors do no support'
                     '  boot from CBS volume).')

flags.DEFINE_boolean(
    'use_security_group', False,
    '(EXPERIMENTAL) A boolean indicating if whether or not to create a security'
    ' group for the new instance. Applies default security group rules'
    ' (e.g. allow ingress TCP, and UDP traffic through port 22). If no security'
    ' group is used, all incoming and outgoing traffic through TCP, UDP and'
    ' ICMP is allowed, this is the default.')

flags.DEFINE_string('rackspace_network_id', None,
                    '(EXPERIMENTAL) The ID of an already '
                    'created network to use instead of creating a new one. '
                    'Must have a subnet already associated with the network.')

flags.DEFINE_list('additional_rackspace_flags',
                  [],
                  'Additional flags to pass to Rackspace.')

@@ -1504,16 +1504,17 @@
 rs do no
+t
  support
@@ -2344,16 +2344,23 @@
 itional 
+global 
 flags to
@@ -2368,21 +2368,86 @@
 pass to 
-Rackspac
+the every '%0A                  'RackCLI command. See %22rack --help%22 for mor
 e.')%0A

Fix typos and improve 'additional_rackspace_flags' help doc