def fetch_inventory(vaultName, jobId): glacier = boto3.resource('glacier') job = glacier.Job(config['accountId'], vaultName, jobId) output = job.get_output() cli.pp(output) inventory = json.loads(output['body'].read()) cli.pp(inventory)
def perform_inventory(vaultName): glacier = boto3.resource('glacier') vault = glacier.Vault(config['accountId'], vaultName) job = vault.initiate_inventory_retrieval() cli.pp(job)
def list_jobs(vaultName): response = client.list_jobs(vaultName=vaultName) cli.pp(response)