Deprecating --api-version flag

This commit is contained in:
nikhiljindal
2016-03-02 17:35:55 -08:00
parent 5cc7790f45
commit 593b78f925
111 changed files with 159 additions and 221 deletions

View File

@@ -29,7 +29,11 @@ type Config struct {
// Legacy field from pkg/api/types.go TypeMeta.
// TODO(jlowdermilk): remove this after eliminating downstream dependencies.
Kind string `json:"kind,omitempty"`
// Version of the schema for this config object.
// DEPRECATED: APIVersion is the preferred api version for communicating with the kubernetes cluster (v1, v2, etc).
// Because a cluster can run multiple API groups and potentially multiple versions of each, it no longer makes sense to specify
// a single value for the cluster version.
// This field isnt really needed anyway, so we are deprecating it without replacement.
// It will be ignored if it is present.
APIVersion string `json:"apiVersion,omitempty"`
// Preferences holds general information to be use for cli interactions
Preferences Preferences `json:"preferences"`

View File

@@ -44,13 +44,11 @@ func ExampleOfOptionsConfig() {
defaultConfig.Preferences.Colors = true
defaultConfig.Clusters["alfa"] = &Cluster{
Server: "https://alfa.org:8080",
APIVersion: "v1",
InsecureSkipTLSVerify: true,
CertificateAuthority: "path/to/my/cert-ca-filename",
}
defaultConfig.Clusters["bravo"] = &Cluster{
Server: "https://bravo.org:8080",
APIVersion: "v1",
InsecureSkipTLSVerify: false,
}
defaultConfig.AuthInfos["white-mage-via-cert"] = &AuthInfo{
@@ -86,13 +84,11 @@ func ExampleOfOptionsConfig() {
// clusters:
// alfa:
// LocationOfOrigin: ""
// api-version: v1
// certificate-authority: path/to/my/cert-ca-filename
// insecure-skip-tls-verify: true
// server: https://alfa.org:8080
// bravo:
// LocationOfOrigin: ""
// api-version: v1
// server: https://bravo.org:8080
// contexts:
// alfa-as-black-mage:

View File

@@ -28,7 +28,11 @@ type Config struct {
// Legacy field from pkg/api/types.go TypeMeta.
// TODO(jlowdermilk): remove this after eliminating downstream dependencies.
Kind string `json:"kind,omitempty"`
// Version of the schema for this config object.
// DEPRECATED: APIVersion is the preferred api version for communicating with the kubernetes cluster (v1, v2, etc).
// Because a cluster can run multiple API groups and potentially multiple versions of each, it no longer makes sense to specify
// a single value for the cluster version.
// This field isnt really needed anyway, so we are deprecating it without replacement.
// It will be ignored if it is present.
APIVersion string `json:"apiVersion,omitempty"`
// Preferences holds general information to be use for cli interactions
Preferences Preferences `json:"preferences"`