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

Laravel Google Drive Storage Laravel Package

yaza/laravel-google-drive-storage

Laravel filesystem driver that lets you use Google Drive as a native storage disk. Configure a service account, then upload, download, list, and stream files through Laravel's Storage facade like any other disk. Supports folders, metadata, and seamless integration into existing Laravel apps.

View on GitHub
Deep Wiki
Context7

Technical Evaluation

Architecture fit. The package targets the one seam in Laravel where a third-party backend is cheapest to adopt: the Storage facade / Illuminate\Filesystem\FilesystemManager. Expect a Flysystem adapter registered as a custom disk driver (filesystems.disks.drive.driver = google-drive) plus a service provider and a credentials block (service account JSON or OAuth client/refresh token). Architecturally this is the right shape — application code keeps talking Storage::disk('drive')->put(...) and stays unaware of Google. The real architectural question is not Laravel fit but whether Google Drive's document-store semantics (ID-addressed items, duplicate names permitted in a folder, no atomic rename, no true directories) map cleanly onto Flysystem's path-based contract. Every rough edge in this package will come from that impedance mismatch, not from Laravel.

Integration feasibility. Low-friction on paper: composer require yaza/laravel-google-drive-storage, publish config, add a disk, done. Credential provisioning is the actual work — a GCP project, Drive API enabled, service account created, and the service account granted access to a specific folder or Shared Drive. That is IAM work, not code work, and it is where most POCs stall. Feasibility is high for read/write/list on moderately sized files; unproven for anything exotic.

Technical risk. Concentrated in four places:

  1. Adoption signal. 213 stars and 0 dependents against a composite score of ~13.9 is a weak ecosystem signal. Stars measure interest; dependents measure production trust. Zero dependents means effectively no independent evidence that this runs at scale.
  2. Bus factor. Single-maintainer community package, MIT, no commercial support. If the maintainer stops, we own the fork.
  3. API-semantics leakage. Folder-ID resolution per path, non-resumable uploads, listing latency, and duplicate-name ambiguity can each turn into a production incident that looks like "the package is broken" but is really "Drive is not S3."
  4. Compatibility drift. Flysystem 1/2/3 and Laravel 9/10/11/12 support matrices are the usual breakage point; a major-version bump of league/flysystem can strand us.

Key questions to put to the maintainer (or answer in a spike):

  • Which league/flysystem major version(s), and which Laravel/PHP versions, are supported and CI-tested?
  • Service account, OAuth refresh token, or both? Is domain-wide delegation supported?
  • Shared Drive support, or My Drive only? How are permissions inherited?
  • Are uploads streamed and resumable, or buffered in memory? What is the tested max file size?
  • Is folder-ID lookup cached, or does every path resolve via N API calls? This is the single biggest throughput determinant.
  • How are Google 403 rateLimitExceeded / 404 / 401 errors mapped into Flysystem exceptions?
  • Does it proxy downloads through PHP, or hand back a signed/streamed URL? This decides whether it can serve user-facing assets.
  • Test coverage, CI status, release cadence, and stated support policy.

Integration Approach

Stack fit. Good for a Laravel app that already treats object storage as an implementation detail — background jobs writing exports, user-uploaded documents, archival of generated reports, admin-triggered backups. Poor fit for anything with hard latency budgets, high request throughput, or CDN-fronted static assets.

Compatibility. Pin the package and audit composer why-not against our existing league/flysystem* and guzzlehttp/guzzle constraints before committing. A version conflict here surfaces as a failed install late in the sprint, so resolve it in the first hour of the spike.

Migration path. Do not swap the default disk. Sequence it:

  1. Spike (1–2 days). Stand up a sandbox GCP project, service account, and a dedicated Shared Drive folder. Exercise put, get, exists, delete, files, allFiles, url, and a ~100 MB file. Time the listing calls.
  2. Abstract behind a port. Introduce a thin internal interface (or at minimum a config-driven disk name) so the Drive driver is swappable for S3/GCS without touching call sites. This is the cheapest insurance we can buy against the bus-factor risk.
  3. Add as a secondary disk. Register drive alongside the existing default. Feature-flag by disk name in config/env. No production reads from Drive yet.
  4. Write-path cutover for one non-critical workload. Backups, exports, or logs — something where a 30-minute failure is survivable.
  5. Backfill via a queued copy job, throttled to stay under Drive quota.
  6. Read-path cutover only after a soak period, with the old disk retained read-only as rollback.

Sequencing constraints. Auth provisioning must precede all code work — it is the critical path, not the composer install. And the "swap out later" interface should land before the first production write, not after; retrofitting it post-migration costs an order of magnitude more.

Operational Impact

Maintenance. We should assume we are co-owners, not customers. Budget: pin the version, subscribe to releases, and reserve capacity to vendor or fork if upstream goes quiet. The MIT license permits it; the absence of dependents means we should plan for it rather than hope. Track Google's Drive API deprecations independently of the package — the maintainer may be slower than the platform.

Support. No SLA, no vendor to escalate to. We need an internal runbook covering token rotation, service-account re-grant, quota diagnosis, and disk fallback. Also flag the OAuth consent-screen verification requirement if user-facing scopes are ever used — that is a multi-week Google review, not a config change.

Scaling. Drive enforces per-user and per-project rate limits (quota units per 100 seconds) and is not built for high request volume. Three practical ceilings:

  • Request rate. Small files and metadata-heavy loops will hit rateLimitExceeded first. Needs retry-with-backoff and, realistically, write batching or throttling.
  • Path resolution cost. If each logical path triggers folder-ID lookups, throughput collapses and cost/latency scale with path depth. Demand caching, or cache in our own layer.
  • Listing performance. Large directory listings are slow and paginated; never put a Drive listing on a synchronous user request.

Verdict from a capacity standpoint: suitable for low-to-moderate volume, asymmetric workloads (many writes, few listing reads), and internal/back-office files. Not suitable as a primary store for user-facing media or high-QPS traffic.

Failure modes to design for. Expired or revoked refresh token; service account removed from the shared folder (silent 404s that look like data loss); quota exhaustion under burst; Google 5xx and transient network faults; duplicate filenames making path lookup nondeterministic; partial uploads leaving orphaned files; delete semantics differing from expectations (trash vs. hard delete) affecting retention and compliance posture; and permission inheritance surprising users who can see a file in Drive but not in the app. Each needs an explicit detection and fallback, with the disk-level fallback the most important.

Ramp-up. For Laravel developers, hours — the Storage API is familiar and the config is conventional. For the platform/ops side, days — GCP project setup, service-account scoping, Shared Drive permissions, and quota monitoring are the real learning curve. Plan one engineer-owner with IAM literacy, not just a Laravel generalist.

Bottom line. Technically sound, architecturally well-placed, and cheap to trial — but the adoption signals (0 dependents, solo maintainer, thin description) mean it should enter as an experiment behind an abstraction, not as a committed dependency. Fund the spike and the port interface; gate production cutover on the answers to the questions above.

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.
se7enxweb/flysystem
lampwick/laravel
jeslage/statamic-emojis
micahdshackelford/rmap-laravel
draftsmaninc/draftsman
square-bit/laravel-volition
himito/laravel-mailman
htinlynn/genius-helper
maco-studios/hephaestus
elmogy/larafast
xeviant/laravel-paystack
gorilladash/laravel-website-sdk
martialbe/flysystem-oss
chondal/3312client
jeroen-g/flickr
opscale-co/nova-genbi
itsjustvita/laravel-retention
tequilarapido/trackit
gregsphotography/site-builder-filament
cabaoctavio/laravel-query-log