June 2018
Intermediate to advanced
372 pages
8h 44m
English
For those who do not intend to use Web Console. Life-cycle management can also be handled by gsutil command line using a JSON file to pass life-cycle configurations.
{"lifecycle": { "rule": [ { "action": { "type": "SetStorageClass", "storageClass": "NEARLINE" }, "condition": { "age": 365, "matchesStorageClass": ["MULTI_REGIONAL", "STANDARD", "DURABLE_REDUCED_AVAILABILITY"] } }, { "action": { "type": "SetStorageClass", "storageClass": "COLDLINE" }, "condition": { "age": 1095, "matchesStorageClass": ["NEARLINE"] } }]}}
gsutil lifecycle set [JSON file] gs://[YOUR CLOUD ...