courses/dev-depl-windows/lb-aspnet/common/password.py
def GenerateConfig(context):
  """Entry function to generate the DM config."""
  props = context.properties
  length = props.setdefault(PROPERTY_LENGTH, MIN_LENGTH)
  include_symbols = props.setdefault(PROPERTY_INCLUDE_SYMBOLS, False)

  if not isinstance(include_symbols, bool):
    raise InputError('%s must be a boolean' % PROPERTY_INCLUDE_SYMBOLS)

  content = {
      'resources': [],
      'outputs': [{
          'name': 'password',
          'value': GeneratePassword(length, include_symbols)
      }]
  }
  return yaml.dump(content)
Entry function to generate the DM config.
Entry function to generate the DM config.
Entry function to generate the DM config .
def GenerateConfig(context):
  props = context.properties
  length = props.setdefault(PROPERTY_LENGTH, MIN_LENGTH)
  include_symbols = props.setdefault(PROPERTY_INCLUDE_SYMBOLS, False)
  if not isinstance(include_symbols, bool):
    raise InputError('%s must be a boolean' % PROPERTY_INCLUDE_SYMBOLS)
  content = {
      'resources': [],
      'outputs': [{
          'name': 'password',
          'value': GeneratePassword(length, include_symbols)
      }]
  }
  return yaml.dump(content)
def GenerateConfig ( context ) : props = context . properties length = props . setdefault ( PROPERTY_LENGTH , MIN_LENGTH ) include_symbols = props . setdefault ( PROPERTY_INCLUDE_SYMBOLS , False ) if not isinstance ( include_symbols , bool ) : raise InputError ( '%s must be a boolean' % PROPERTY_INCLUDE_SYMBOLS ) content = { 'resources' : [ ] , 'outputs' : [ { 'name' : 'password' , 'value' : GeneratePassword ( length , include_symbols ) } ] } return yaml . dump ( content )
Entry function to generate the DM config.
Entry function to generate the DM config .
"""Entry function to generate the DM config."""
context