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 Php K8S

Laravel Php K8S Laravel Package

renoki-co/laravel-php-k8s

Laravel PHP K8s is a Laravel-friendly wrapper around the Kubernetes PHP client, simplifying cluster configuration and letting you query, create, and manage Kubernetes resources from your app with fluent, familiar APIs. It streamlines service-account and kubeconfig setup for automation, deployments,...

View on GitHub
Deep Wiki
Context7

Just a simple port of renoki-co/php-k8s for easier access in Laravel

Frequently asked questions about Laravel Php K8S
How do I install laravel-php-k8s in a Laravel application?
Install it with Composer using composer require renoki-co/laravel-php-k8s; the package registers a Laravel service provider so the underlying Kubernetes client is available through the container. Note that version 3.4.0 requires PHP 8.0 or newer and Laravel 8.x or 9.x. After installing, configure your cluster connection using either a kubeconfig file or an in-cluster service account before issuing any API calls.
Which Laravel and PHP versions does version 3.4.0 support?
Version 3.4.0 supports Laravel 8.x and 9.x on PHP 8.0 and above. That release dropped PHP 7.3 and 7.4 as well as Laravel 7.x support, so legacy stacks cannot adopt it without a platform upgrade. Confirm the exact PHP minor versions validated in the repository's CI matrix, such as 8.1, before committing to it.
What is the difference between laravel-php-k8s and renoki-co/php-k8s?
Laravel PHP K8s is a simple port of renoki-co/php-k8s made for easier access inside Laravel. It adds Laravel-friendly wiring, such as service provider registration and container access, over the same underlying Kubernetes PHP client. Because the core client is shared, Kubernetes API compatibility and resource behaviour are inherited from php-k8s.
How do I configure cluster credentials, kubeconfig or a service account?
You can point the package at a kubeconfig file for local or out-of-cluster usage, or rely on service-account credentials when the Laravel app runs inside the cluster. Whichever route you take, create a dedicated service account with least-privilege RBAC rather than embedding cluster-admin tokens in configuration or environment variables. Credential rotation and injection should be handled by your platform tooling, not hard-coded in the app.
What Kubernetes resources can I manage from Laravel with this package?
Because it wraps the php-k8s client, you can list, create, and manage common resources such as deployments, pods, config maps, jobs, and namespaces using fluent PHP calls. Typical uses are internal admin panels, self-service namespace provisioning, deployment automation, and cluster inspection from the application layer. The package does not abstract away Kubernetes API version differences, so verify behaviour against your target cluster version.
Is laravel-php-k8s safe to use in production?
It is reasonable for internal tooling, admin panels, CI/CD helpers, and platform automation, provided the app uses a least-privilege service account and you keep audit logging on. It is not intended for high-frequency reconciliation loops or latency-sensitive cluster operations, which belong in a controller or operator. Put write operations behind a feature flag, roll out incrementally, and have a rollback plan.
How do I test Kubernetes integration without breaking a real cluster?
Prototype read-only calls such as listing pods and fetching deployments against a non-production cluster like kind or minikube before touching staging or production. For unit tests, wrap the client behind your own interface so you can substitute a fake and avoid real API server calls. Add write operations only after read paths are verified and monitored.
Does it work with any Kubernetes version?
Kubernetes compatibility is inherited from the underlying php-k8s client, so supported API versions track that project rather than this wrapper. The package does not smooth over API version skew, so test against the exact cluster version you run in production. Also check that your admission controllers, network policies, and RBAC model behave as expected in staging first.
Is laravel-php-k8s actively maintained and commercially supported?
It is a community-maintained package from renoki-co with a relatively small maintainer base, and there is no documented commercial support offering. Before depending on it for critical automation, review recent commit and issue activity, the CI test matrix, and any security policy for reporting vulnerabilities. If long-term support is a hard requirement, evaluate the official Kubernetes PHP client as a lower-level alternative you control directly.
What is the upgrade path to 3.4.0 from older versions?
Because 3.4.0 drops PHP 7.3/7.4 and Laravel 7.x in what is technically a minor release, treat it as a planned platform upgrade rather than a routine dependency bump. Upgrade the runtime to PHP 8.0+ and the framework to Laravel 8.x or 9.x first, then adopt 3.4.0. Keep a rollback path to the last compatible package version in case the runtime upgrade slips, and confirm the documented upgrade steps for 2.x and 3.x in the repository.
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.
socialdept/atp-orm
cboxdk/laravel-assistant-client
socialdept/atp-resolver
socialdept/tenant-domains
tautvydasr/blade-class-names
socialdept/color-scales
maherelgamil/controller
coleus/widgets
coleus/table
coleus/users
coleus/music
coleus/health
coleus/calendar
coleus/notes
coleus/support
coleus/settings
coleus/apps
seampact/laravel
emmyconceptng/laravel-ng-postcode
jjsquady/round-robin