A gaming studio's DevOps team is provisioning a new Google Cloud Storage bucket named `game-patch-assets-global` in the `us-central1` region using the modern `gcloud storage` CLI tool. The bucket will store high-volume patch updates for client distribution. The team must enforce centralized IAM access permissions across all objects while disabling legacy per-object Access Control Lists (ACLs). Additionally, they need to ensure that patch files older than 30 days automatically transition from Standard to Nearline storage to minimize ongoing storage fees. Which TWO commands or configuration steps must the team execute to fulfill these requirements? (Select TWO.)
- Execute `gcloud storage buckets create gs://game-patch-assets-global --location=us-central1 --uniform-bucket-level-access` to create the bucket with unified IAM access control enabled.Answer
- BExecute `gsutil mb -c standard -l us-central1 gs://game-patch-assets-global` and configure public read access using `gsutil acl set public-read gs://game-patch-assets-global`.
- Execute `gcloud storage buckets update gs://game-patch-assets-global --lifecycle-file=lifecycle.json` with a configuration specifying an `Age` condition of 30 days and a `SetStorageClass` action of `NEARLINE`.Answer
- DExecute `gcloud storage objects update gs://game-patch-assets-global/* --add-acl-grant=entity=AllUsers,role=READER` to configure object-level permissions individually after deployment.
Answer
The team must provision the bucket using `gcloud storage buckets create gs://game-patch-assets-global --location=us-central1 --uniform-bucket-level-access` and update the bucket's lifecycle policy using `gcloud storage buckets update gs://game-patch-assets-global --lifecycle-file=lifecycle.json` containing an Age condition of 30 days and a SetStorageClass action of NEARLINE.
Provisioning the Cloud Storage bucket with `gcloud storage buckets create` along with the `--uniform-bucket-level-access` flag enforces unified IAM permissions and disables object ACLs. Updating the bucket with `gcloud storage buckets update --lifecycle-file=lifecycle.json` successfully attaches the lifecycle condition to transition 30-day-old objects from Standard to Nearline storage class.
Step-by-Step Solution
Key Concept
Deploying Cloud Storage buckets with Uniform Bucket-Level Access and applying Object Lifecycle Management rules using gcloud storage CLI.