Skip to content

Commit 20e6883

Browse files
authored
Merge pull request kubernetes#88290 from tallclair/spr-deprecate
Start deprecation process for StreamingProxyRedirects
2 parents 0943976 + 98ad741 commit 20e6883

File tree

3 files changed

+6
-2
lines changed

3 files changed

+6
-2
lines changed

pkg/features/kube_features.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -627,7 +627,7 @@ var defaultKubernetesFeatureGates = map[featuregate.Feature]featuregate.FeatureS
627627

628628
// inherited features from generic apiserver, relisted here to get a conflict if it is changed
629629
// unintentionally on either side:
630-
genericfeatures.StreamingProxyRedirects: {Default: true, PreRelease: featuregate.Beta},
630+
genericfeatures.StreamingProxyRedirects: {Default: true, PreRelease: featuregate.Deprecated},
631631
genericfeatures.ValidateProxyRedirects: {Default: true, PreRelease: featuregate.Beta},
632632
genericfeatures.AdvancedAuditing: {Default: true, PreRelease: featuregate.GA},
633633
genericfeatures.DynamicAuditing: {Default: false, PreRelease: featuregate.Alpha},

pkg/kubelet/config/flags.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@ func (s *ContainerRuntimeOptions) AddFlags(fs *pflag.FlagSet) {
8686
fs.StringVar(&s.ContainerRuntime, "container-runtime", s.ContainerRuntime, "The container runtime to use. Possible values: 'docker', 'remote'.")
8787
fs.StringVar(&s.RuntimeCgroups, "runtime-cgroups", s.RuntimeCgroups, "Optional absolute name of cgroups to create and run the runtime in.")
8888
fs.BoolVar(&s.RedirectContainerStreaming, "redirect-container-streaming", s.RedirectContainerStreaming, "Enables container streaming redirect. If false, kubelet will proxy container streaming data between apiserver and container runtime; if true, kubelet will return an http redirect to apiserver, and apiserver will access container runtime directly. The proxy approach is more secure, but introduces some overhead. The redirect approach is more performant, but less secure because the connection between apiserver and container runtime may not be authenticated.")
89+
fs.MarkDeprecated("redirect-container-streaming", "Container streaming redirection will be removed from the kubelet in v1.20, and this flag will be removed in v1.22. For more details, see http://git.k8s.io/enhancements/keps/sig-node/20191205-container-streaming-requests.md")
8990

9091
// Docker-specific settings.
9192
fs.BoolVar(&s.ExperimentalDockershim, "experimental-dockershim", s.ExperimentalDockershim, "Enable dockershim only mode. In this mode, kubelet will only start dockershim without any other functionalities. This flag only serves test purpose, please do not use it unless you are conscious of what you are doing. [default=false]")

staging/src/k8s.io/apiserver/pkg/features/kube_features.go

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,12 @@ const (
3333
// owner: @tallclair
3434
// alpha: v1.5
3535
// beta: v1.6
36+
// deprecated: v1.18
3637
//
3738
// StreamingProxyRedirects controls whether the apiserver should intercept (and follow)
3839
// redirects from the backend (Kubelet) for streaming requests (exec/attach/port-forward).
40+
//
41+
// This feature is deprecated, and will be removed in v1.22.
3942
StreamingProxyRedirects featuregate.Feature = "StreamingProxyRedirects"
4043

4144
// owner: @tallclair
@@ -156,7 +159,7 @@ func init() {
156159
// To add a new feature, define a key for it above and add it here. The features will be
157160
// available throughout Kubernetes binaries.
158161
var defaultKubernetesFeatureGates = map[featuregate.Feature]featuregate.FeatureSpec{
159-
StreamingProxyRedirects: {Default: true, PreRelease: featuregate.Beta},
162+
StreamingProxyRedirects: {Default: true, PreRelease: featuregate.Deprecated},
160163
ValidateProxyRedirects: {Default: true, PreRelease: featuregate.Beta},
161164
AdvancedAuditing: {Default: true, PreRelease: featuregate.GA},
162165
DynamicAuditing: {Default: false, PreRelease: featuregate.Alpha},

0 commit comments

Comments
 (0)