This commit is contained in:
Steve Pulec 2017-02-23 21:37:43 -05:00
commit f37bad0e00
260 changed files with 6363 additions and 3766 deletions

View file

@ -1,6 +1,6 @@
from __future__ import unicode_literals
from .models import glacier_backends
from ..core.models import MockAWS, base_decorator, HttprettyMockAWS, deprecated_base_decorator
from ..core.models import base_decorator, deprecated_base_decorator
glacier_backend = glacier_backends['us-east-1']
mock_glacier = base_decorator(glacier_backends)

View file

@ -36,6 +36,7 @@ class ArchiveJob(object):
class Vault(object):
def __init__(self, vault_name, region):
self.vault_name = vault_name
self.region = region

View file

@ -128,7 +128,8 @@ class GlacierResponse(_TemplateEnvironmentMixin):
archive_id = json_body['ArchiveId']
job_id = self.backend.initiate_job(vault_name, archive_id)
headers['x-amz-job-id'] = job_id
headers['Location'] = "/{0}/vaults/{1}/jobs/{2}".format(account_id, vault_name, job_id)
headers[
'Location'] = "/{0}/vaults/{1}/jobs/{2}".format(account_id, vault_name, job_id)
return 202, headers, ""
@classmethod