Weave Code
Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Cloud Storage Laravel Package

google/cloud-storage

Google Cloud Storage for PHP is an idiomatic client for uploading, downloading, and managing objects and buckets, with ACL support, a gs:// stream wrapper, and simple Composer installation.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Global Media Delivery: Replace self-hosted CDNs or S3 alternatives (e.g., Wasabi) for serving static assets (images, videos, fonts) with Google’s multi-regional storage and CDN integration, reducing latency for global users.
  • Laravel Ecosystem Integration:
    • File Uploads: Seamlessly replace spatie/laravel-medialibrary or intervention/image backends with resumable uploads, metadata tagging, and ACL-based permissions (e.g., publicRead for profile pictures).
    • Livewire/Tailwind: Serve versioned static assets (e.g., app.[hash].js) with cache-control headers via gs:// URLs, leveraging Google’s 2TB object size limit for large bundles.
    • Queued Processing: Offload video transcoding or PDF generation to Laravel Queues, using Cloud Storage as a source/sink for intermediate files (e.g., storage.googleapis.com/processing-queue/).
  • Compliance & Retention:
    • Soft-Delete & Legal Holds: Enable object versioning and retention policies (e.g., 7-year HIPAA compliance) via softDelete and restoreToken features.
    • Encryption Enforcement: Mandate customer-managed keys (CMEK) or bucket-level encryption for sensitive data (e.g., medical records).
  • Cost Optimization:
    • Lifecycle Rules: Auto-migrate old files to Coldline/Archive Storage (90% cheaper) using object lifecycle management (e.g., move files >90 days old to NEARLINE).
    • Intelligent Tiering: Use Storage Class transitions (e.g., STANDARD → COLDLINE) to reduce costs for rarely accessed files.
  • Build vs. Buy:
    • Buy: Ideal for teams without DevOps resources to manage S3/SwiftStack clusters or Ceph storage.
    • Build: Only if requiring custom sharding logic or hybrid on-prem/Cloud Storage (e.g., for air-gapped compliance).

When to Consider This Package

Adopt if:

  • Your Laravel app handles >100K MAU with high file upload volumes (e.g., social media, e-commerce).
  • You need sub-millisecond latency for global users (Google’s 220+ edge locations vs. self-hosted CDNs).
  • Compliance requires audit logs, immutable storage, or region-locked buckets (e.g., EU-only storage for GDPR).
  • Your team lacks bandwidth to manage S3/SwiftStack clusters, tune cache policies, or monitor storage costs.

Look elsewhere if:

  • You’re all-in on AWS and need native S3 compatibility (use aws-sdk/aws-sdk-php instead).
  • Your files are <1GB and local storage (e.g., local driver in Laravel) suffices.
  • You require block storage (e.g., databases) instead of object storage (use Cloud Filestore or Persistent Disk).
  • Your budget is < $5/month (Google’s Free Tier is limited to 5GB standard storage).

How to Pitch It (Stakeholders)

For Executives: *"This package lets us replace our $2K/month self-hosted storage with Google Cloud Storage—saving costs while scaling infinitely. For example:

  • Global users get faster asset delivery (e.g., videos load 30% faster via Google’s CDN).
  • Compliance teams can enforce retention policies (e.g., auto-delete old logs after 90 days).
  • DevOps avoids managing S3 clusters, freeing time for core features. Cost? We pay ~$0.02/GB for active data and ~$0.004/GB for archives—cheaper than AWS S3 for our scale."*

For Engineers: *"This is a drop-in replacement for Laravel’s filesystem config. Key wins:

  • Resumable uploads: Users can pause/retry large file uploads (e.g., 2GB videos).
  • Streaming API: Treat gs:// like a local filesystem (e.g., file_get_contents('gs://bucket/file.txt')).
  • Laravel Integration: Works with Spatie Media Library, Livewire, and Queues out of the box. Migration? Just update config/filesystems.php and add a service account key—no refactoring needed. Security: Enforce CMEK encryption and VPC Service Controls via Google’s IAM."*

For PMs: *"This unlocks three high-impact features with minimal dev effort:

  1. Global Asset Delivery: Serve user uploads (e.g., profile pics) via Google’s CDN—no more asset() cache misses.
  2. Compliance-Ready Storage: Enable object versioning and legal holds for audits (e.g., ‘retain this contract for 10 years’).
  3. Cost Savings: Auto-tier files to Coldline (90% cheaper) after 90 days—no manual cleanup. Risk: Minimal—Google’s SLA is 99.95% uptime, and the PHP SDK is GA (stable)."*
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
steadrun/laravel-monitor
labyrinthe/connect-laravel
elmogy/layan
drewdan/sentinel-client
dskripchenko/laravel-llm
fatryst/nuonuo
stevenay/myanfont
gmostafa/php-graphql-client
xeviant/paystack
snowsoft/faker
meditationsteps/blogetc
animalyoung/laravel-influxdb
onix-solutions/sms-telera
lonely-lights/prosetta
oxygen/data
oxygen/core
jengo/base
xiloryx/log-collector
a21ns1g4ts/filament-stripe
la-php/laravel-admin