class

Kubernetes::CredentialCache

Inherits Reference < Object

Manages credential caching for exec providers Follows kubectl's caching strategy: ~/.kube/cache/

Constants

CACHE_DIR = File.expand_path("~/.kube/cache")

Constructors

new(log : Log = Log.for("k8s.cache"))
Source

Class methods

key_for_exec(exec : Config::UserEntry::ExecConfig) : String

Generate cache key from exec config

Source

Instance methods

clear_all

Clear all cached credentials

Source
get(key : String) : Auth | Nil

Get cached credential if valid

Source
set(key : String, auth : Auth, expires_at : ::Time | Nil = nil)

Store credential in cache

Source

Nested types