mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-10 13:42:02 +00:00
Rename client Minions->Nodes, select the correct path for v1beta3
Replaces the client public interface but leaves old references to "minions" for a later refactor. Selects the path "nodes" for v1beta3 and "minions" for older versions.
This commit is contained in:
@@ -87,7 +87,9 @@ func New(c *Config) (*Client, error) {
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
return &Client{client}, nil
|
||||
version := defaultVersionFor(&config)
|
||||
isPreV1Beta3 := (version == "v1beta1" || version == "v1beta2")
|
||||
return &Client{client, isPreV1Beta3}, nil
|
||||
}
|
||||
|
||||
// NewOrDie creates a Kubernetes client and panics if the provided API version is not recognized.
|
||||
|
Reference in New Issue
Block a user