Пример #1
0
def _delete_volume_response(response):
    if 'errortext' in response:
        helpers.error_to_aws(response, volume_error_to_aws)

    return {
        'template_name_or_list': 'status.xml',
        'response_type': 'DeleteVolumeResponse',
        'return': 'true'
    }
Пример #2
0
def _attach_volume_response(response):
    if "errortext" in response:
        helpers.error_to_aws(response, volume_error_to_aws)

    response = response["volume"]
    return {
        "template_name_or_list": "volume_attachment.xml",
        "response_type": "AttachVolumeResponse",
        "response": response,
    }
Пример #3
0
def _create_volume_response(response):
    if 'errortext' in response:
        helpers.error_to_aws(response, volume_error_to_aws)

    response = response['volume']
    return {
        'template_name_or_list': 'create_volume.xml',
        'response_type': 'CreateVolumeResponse',
        'response': response
    }
Пример #4
0
def _detach_volume_response(response):
    if 'errortext' in response:
        helpers.error_to_aws(response, volume_error_to_aws)

    response = response['volume']
    return {
        'template_name_or_list': 'volume_attachment.xml',
        'response_type': 'DetachVolumeResponse',
        'response': response
    }
Пример #5
0
def _create_volume_response(response):
    if "errortext" in response:
        helpers.error_to_aws(response, volume_error_to_aws)

    response = response["volume"]
    return {"template_name_or_list": "create_volume.xml", "response_type": "CreateVolumeResponse", "response": response}
Пример #6
0
def _delete_volume_response(response):
    if "errortext" in response:
        helpers.error_to_aws(response, volume_error_to_aws)

    return {"template_name_or_list": "status.xml", "response_type": "DeleteVolumeResponse", "return": "true"}