Edit Firebase Storage bucket lifecycle rules

Inspect Cloud Storage lifecycle rules, apply a JSON configuration, and find the previous version in the QueryCanopy audit log.

Read the bucket configuration

  1. In the correct project, open Storage, select the bucket, and choose Paramètres du bucket.
  2. Check the location and bucket name. Règles de cycle de vie shows the current rules as JSON.
  3. Review the entire list. Saving replaces the rules, and saving an empty list clears the configuration.

Limit a rule to a prefix

This rule applies to objects in the exports/ folder that are at least 90 days old. Cloud Storage changes objects in the STANDARD class to NEARLINE.

[{"action":{"type":"SetStorageClass","storageClass":"NEARLINE"},"condition":{"age":90,"matchesStorageClass":["STANDARD"],"matchesPrefix":["exports/"]}}]

Choose Enregistrer le cycle de vie and confirm the exact bucket name. If the bucket has changed, copy your draft before reloading the settings. Cloud Storage lifecycle conditions and actions

Restore the previous configuration

In Journal, open the Cycle de vie Storage entry and review the rule lists. Choose Restaurer la version Storage while the bucket still matches the recorded version.

Explore Firebase Storage tools