home / skills / jeremylongshore / claude-code-plugins-plus-skills / gcs-lifecycle-policy
This skill guides and automates Google Cloud Storage lifecycle policy tasks with best practices, producing configurations and validation results.
npx playbooks add skill jeremylongshore/claude-code-plugins-plus-skills --skill gcs-lifecycle-policyReview the files below or copy the command above to add this skill to your agents.
---
name: "gcs-lifecycle-policy"
description: |
Manage gcs lifecycle policy operations. Auto-activating skill for GCP Skills.
Triggers on: gcs lifecycle policy, gcs lifecycle policy
Part of the GCP Skills skill category. Use when working with gcs lifecycle policy functionality. Trigger with phrases like "gcs lifecycle policy", "gcs policy", "gcs".
allowed-tools: "Read, Write, Edit, Bash(gcloud:*)"
version: 1.0.0
license: MIT
author: "Jeremy Longshore <[email protected]>"
---
# Gcs Lifecycle Policy
## Overview
This skill provides automated assistance for gcs lifecycle policy tasks within the GCP Skills domain.
## When to Use
This skill activates automatically when you:
- Mention "gcs lifecycle policy" in your request
- Ask about gcs lifecycle policy patterns or best practices
- Need help with google cloud platform skills covering compute, storage, bigquery, vertex ai, and gcp-specific services.
## Instructions
1. Provides step-by-step guidance for gcs lifecycle policy
2. Follows industry best practices and patterns
3. Generates production-ready code and configurations
4. Validates outputs against common standards
## Examples
**Example: Basic Usage**
Request: "Help me with gcs lifecycle policy"
Result: Provides step-by-step guidance and generates appropriate configurations
## Prerequisites
- Relevant development environment configured
- Access to necessary tools and services
- Basic understanding of gcp skills concepts
## Output
- Generated configurations and code
- Best practice recommendations
- Validation results
## Error Handling
| Error | Cause | Solution |
|-------|-------|----------|
| Configuration invalid | Missing required fields | Check documentation for required parameters |
| Tool not found | Dependency not installed | Install required tools per prerequisites |
| Permission denied | Insufficient access | Verify credentials and permissions |
## Resources
- Official documentation for related tools
- Best practices guides
- Community examples and tutorials
## Related Skills
Part of the **GCP Skills** skill category.
Tags: gcp, bigquery, vertex-ai, cloud-run, firebase
This skill automates management of Google Cloud Storage (GCS) lifecycle policies. It helps design, generate, and validate lifecycle rules for object transitions, expirations, and custom conditions. Use it to produce production-ready JSON/YAML configs and actionable guidance for applying policies across buckets.
The skill inspects requested lifecycle goals and produces concrete lifecycle rule configurations (age, createdBefore, matchesPrefix, matchesStorageClass, customTime) compatible with GCS. It validates configurations against common schema rules and best practices, and can generate deployment-ready snippets and command examples for gcloud, Terraform, or REST APIs. When permissions or environment details are missing, it highlights required actions and fixes.
Can this skill apply policies directly to my GCP project?
I provide the configuration and command snippets; applying them requires appropriate gcloud credentials and permissions in your environment.
Which lifecycle rule conditions are supported?
Common conditions like age, createdBefore, customTime, matchesPrefix, matchesSuffix, and matchesStorageClass are supported and validated in generated configs.
Will generated policies avoid data loss?
Generated policies follow best practices and validation checks, but you should test in a non-production bucket and review rules to ensure they match your retention and compliance needs.