NAME
Kubernetes::REST::CLI::Role::Connection - Shared kubeconfig/auth options for CLI tools
VERSION
version 1.107
DESCRIPTION
Moo role providing --kubeconfig and --context options and a lazy api attribute that builds a Kubernetes::REST instance from the kubeconfig.
Consumed by Kubernetes::REST::CLI and Kubernetes::REST::CLI::Watch.
kubeconfig
Path to kubeconfig file. Without it the KUBECONFIG environment variable is used, and without that ~/.kube/config - the same precedence kubectl and Kubernetes::REST::Kubeconfig apply. An explicitly given --kubeconfig wins over KUBECONFIG.
KUBECONFIG may name several files as the :-separated list kubectl merges, in which case they are merged the same way - see "MERGING" in Kubernetes::REST::Kubeconfig. --kubeconfig takes such a list too, since it is passed straight through.
context
Kubernetes context to use from the kubeconfig. Defaults to the current-context.
Short option: -c
api
Lazy Kubernetes::REST instance built from the kubeconfig.
The kubeconfig it is built from is --kubeconfig if given, otherwise $ENV{KUBECONFIG}, otherwise ~/.kube/config. Either of the first two may be a :-separated list of files, which is merged as kubectl merges it.
SEE ALSO
Kubernetes::REST::Kubeconfig - Kubeconfig parser
Kubernetes::REST::CLI - CLI base class
Kubernetes::REST::CLI::Watch - Watch CLI tool
SUPPORT
Issues
Please report bugs and feature requests on GitHub at https://github.com/pplu/kubernetes-rest/issues.
IRC
Join #kubernetes on irc.perl.org or message Getty directly.
CONTRIBUTING
Contributions are welcome! Please fork the repository and submit a pull request.
AUTHORS
Torsten Raudssus <getty@cpan.org>
Jose Luis Martinez Torres <jlmartin@cpan.org>
COPYRIGHT AND LICENSE
This software is Copyright (c) 2019-2026 by Jose Luis Martinez Torres <jlmartin@cpan.org>.
This is free software, licensed under:
The Apache License, Version 2.0, January 2004