mirror of https://github.com/kubernetes/kops.git
pkg/apis/kops: Allow configuring dockerd --max-* upload and download concurrency and retry options.
YAML config options are maxConcurrentDownloads, maxConcurrentUploads, and maxDownloadAttempts. Defaults are maxConcurrentDownloads=3, maxConcurrentUploads=5, and maxDownloadAttempts=5.
This commit is contained in:
parent
924e68c381
commit
12e938557e
|
@ -836,6 +836,21 @@ spec:
|
||||||
items:
|
items:
|
||||||
type: string
|
type: string
|
||||||
type: array
|
type: array
|
||||||
|
maxConcurrentDownloads:
|
||||||
|
description: MaxConcurrentDownloads sets the max concurrent downloads
|
||||||
|
for each pull
|
||||||
|
format: int32
|
||||||
|
type: integer
|
||||||
|
maxConcurrentUploads:
|
||||||
|
description: MaxConcurrentUploads sets the max concurrent uploads
|
||||||
|
for each push
|
||||||
|
format: int32
|
||||||
|
type: integer
|
||||||
|
maxDownloadAttempts:
|
||||||
|
description: MaxDownloadAttempts sets the max download attempts
|
||||||
|
for each pull
|
||||||
|
format: int32
|
||||||
|
type: integer
|
||||||
metricsAddress:
|
metricsAddress:
|
||||||
description: Metrics address is the endpoint to serve with Prometheus
|
description: Metrics address is the endpoint to serve with Prometheus
|
||||||
format metrics
|
format metrics
|
||||||
|
|
|
@ -56,6 +56,12 @@ type DockerConfig struct {
|
||||||
LogLevel *string `json:"logLevel,omitempty" flag:"log-level"`
|
LogLevel *string `json:"logLevel,omitempty" flag:"log-level"`
|
||||||
// Logopt is a series of options given to the log driver options for containers
|
// Logopt is a series of options given to the log driver options for containers
|
||||||
LogOpt []string `json:"logOpt,omitempty" flag:"log-opt,repeat"`
|
LogOpt []string `json:"logOpt,omitempty" flag:"log-opt,repeat"`
|
||||||
|
// MaxConcurrentDownloads sets the max concurrent downloads for each pull
|
||||||
|
MaxConcurrentDownloads *int32 `json:"maxConcurrentDownloads,omitempty" flag:"max-concurrent-downloads"`
|
||||||
|
// MaxConcurrentUploads sets the max concurrent uploads for each push
|
||||||
|
MaxConcurrentUploads *int32 `json:"maxConcurrentUploads,omitempty" flag:"max-concurrent-uploads"`
|
||||||
|
// MaxDownloadAttempts sets the max download attempts for each pull
|
||||||
|
MaxDownloadAttempts *int32 `json:"maxDownloadAttempts,omitempty" flag:"max-download-attempts"`
|
||||||
// Metrics address is the endpoint to serve with Prometheus format metrics
|
// Metrics address is the endpoint to serve with Prometheus format metrics
|
||||||
MetricsAddress *string `json:"metricsAddress,omitempty" flag:"metrics-addr"`
|
MetricsAddress *string `json:"metricsAddress,omitempty" flag:"metrics-addr"`
|
||||||
// MTU is the containers network MTU
|
// MTU is the containers network MTU
|
||||||
|
|
|
@ -56,6 +56,12 @@ type DockerConfig struct {
|
||||||
LogLevel *string `json:"logLevel,omitempty" flag:"log-level"`
|
LogLevel *string `json:"logLevel,omitempty" flag:"log-level"`
|
||||||
// Logopt is a series of options given to the log driver options for containers
|
// Logopt is a series of options given to the log driver options for containers
|
||||||
LogOpt []string `json:"logOpt,omitempty" flag:"log-opt,repeat"`
|
LogOpt []string `json:"logOpt,omitempty" flag:"log-opt,repeat"`
|
||||||
|
// MaxConcurrentDownloads sets the max concurrent downloads for each pull
|
||||||
|
MaxConcurrentDownloads *int32 `json:"maxConcurrentDownloads,omitempty" flag:"max-concurrent-downloads"`
|
||||||
|
// MaxConcurrentUploads sets the max concurrent uploads for each push
|
||||||
|
MaxConcurrentUploads *int32 `json:"maxConcurrentUploads,omitempty" flag:"max-concurrent-uploads"`
|
||||||
|
// MaxDownloadAttempts sets the max download attempts for each pull
|
||||||
|
MaxDownloadAttempts *int32 `json:"maxDownloadAttempts,omitempty" flag:"max-download-attempts"`
|
||||||
// Metrics address is the endpoint to serve with Prometheus format metrics
|
// Metrics address is the endpoint to serve with Prometheus format metrics
|
||||||
MetricsAddress *string `json:"metricsAddress,omitempty" flag:"metrics-addr"`
|
MetricsAddress *string `json:"metricsAddress,omitempty" flag:"metrics-addr"`
|
||||||
// MTU is the containers network MTU
|
// MTU is the containers network MTU
|
||||||
|
|
|
@ -3367,6 +3367,9 @@ func autoConvert_v1alpha2_DockerConfig_To_kops_DockerConfig(in *DockerConfig, ou
|
||||||
out.LogDriver = in.LogDriver
|
out.LogDriver = in.LogDriver
|
||||||
out.LogLevel = in.LogLevel
|
out.LogLevel = in.LogLevel
|
||||||
out.LogOpt = in.LogOpt
|
out.LogOpt = in.LogOpt
|
||||||
|
out.MaxConcurrentDownloads = in.MaxConcurrentDownloads
|
||||||
|
out.MaxConcurrentUploads = in.MaxConcurrentUploads
|
||||||
|
out.MaxDownloadAttempts = in.MaxDownloadAttempts
|
||||||
out.MetricsAddress = in.MetricsAddress
|
out.MetricsAddress = in.MetricsAddress
|
||||||
out.MTU = in.MTU
|
out.MTU = in.MTU
|
||||||
if in.Packages != nil {
|
if in.Packages != nil {
|
||||||
|
@ -3414,6 +3417,9 @@ func autoConvert_kops_DockerConfig_To_v1alpha2_DockerConfig(in *kops.DockerConfi
|
||||||
out.LogDriver = in.LogDriver
|
out.LogDriver = in.LogDriver
|
||||||
out.LogLevel = in.LogLevel
|
out.LogLevel = in.LogLevel
|
||||||
out.LogOpt = in.LogOpt
|
out.LogOpt = in.LogOpt
|
||||||
|
out.MaxConcurrentDownloads = in.MaxConcurrentDownloads
|
||||||
|
out.MaxConcurrentUploads = in.MaxConcurrentUploads
|
||||||
|
out.MaxDownloadAttempts = in.MaxDownloadAttempts
|
||||||
out.MetricsAddress = in.MetricsAddress
|
out.MetricsAddress = in.MetricsAddress
|
||||||
out.MTU = in.MTU
|
out.MTU = in.MTU
|
||||||
if in.Packages != nil {
|
if in.Packages != nil {
|
||||||
|
|
|
@ -1506,6 +1506,21 @@ func (in *DockerConfig) DeepCopyInto(out *DockerConfig) {
|
||||||
*out = make([]string, len(*in))
|
*out = make([]string, len(*in))
|
||||||
copy(*out, *in)
|
copy(*out, *in)
|
||||||
}
|
}
|
||||||
|
if in.MaxConcurrentDownloads != nil {
|
||||||
|
in, out := &in.MaxConcurrentDownloads, &out.MaxConcurrentDownloads
|
||||||
|
*out = new(int32)
|
||||||
|
**out = **in
|
||||||
|
}
|
||||||
|
if in.MaxConcurrentUploads != nil {
|
||||||
|
in, out := &in.MaxConcurrentUploads, &out.MaxConcurrentUploads
|
||||||
|
*out = new(int32)
|
||||||
|
**out = **in
|
||||||
|
}
|
||||||
|
if in.MaxDownloadAttempts != nil {
|
||||||
|
in, out := &in.MaxDownloadAttempts, &out.MaxDownloadAttempts
|
||||||
|
*out = new(int32)
|
||||||
|
**out = **in
|
||||||
|
}
|
||||||
if in.MetricsAddress != nil {
|
if in.MetricsAddress != nil {
|
||||||
in, out := &in.MetricsAddress, &out.MetricsAddress
|
in, out := &in.MetricsAddress, &out.MetricsAddress
|
||||||
*out = new(string)
|
*out = new(string)
|
||||||
|
|
|
@ -56,6 +56,12 @@ type DockerConfig struct {
|
||||||
LogLevel *string `json:"logLevel,omitempty" flag:"log-level"`
|
LogLevel *string `json:"logLevel,omitempty" flag:"log-level"`
|
||||||
// Logopt is a series of options given to the log driver options for containers
|
// Logopt is a series of options given to the log driver options for containers
|
||||||
LogOpt []string `json:"logOpt,omitempty" flag:"log-opt,repeat"`
|
LogOpt []string `json:"logOpt,omitempty" flag:"log-opt,repeat"`
|
||||||
|
// MaxConcurrentDownloads sets the max concurrent downloads for each pull
|
||||||
|
MaxConcurrentDownloads *int32 `json:"maxConcurrentDownloads,omitempty" flag:"max-concurrent-downloads"`
|
||||||
|
// MaxConcurrentUploads sets the max concurrent uploads for each push
|
||||||
|
MaxConcurrentUploads *int32 `json:"maxConcurrentUploads,omitempty" flag:"max-concurrent-uploads"`
|
||||||
|
// MaxDownloadAttempts sets the max download attempts for each pull
|
||||||
|
MaxDownloadAttempts *int32 `json:"maxDownloadAttempts,omitempty" flag:"max-download-attempts"`
|
||||||
// Metrics address is the endpoint to serve with Prometheus format metrics
|
// Metrics address is the endpoint to serve with Prometheus format metrics
|
||||||
MetricsAddress *string `json:"metricsAddress,omitempty" flag:"metrics-addr"`
|
MetricsAddress *string `json:"metricsAddress,omitempty" flag:"metrics-addr"`
|
||||||
// MTU is the containers network MTU
|
// MTU is the containers network MTU
|
||||||
|
|
|
@ -3281,6 +3281,9 @@ func autoConvert_v1alpha3_DockerConfig_To_kops_DockerConfig(in *DockerConfig, ou
|
||||||
out.LogDriver = in.LogDriver
|
out.LogDriver = in.LogDriver
|
||||||
out.LogLevel = in.LogLevel
|
out.LogLevel = in.LogLevel
|
||||||
out.LogOpt = in.LogOpt
|
out.LogOpt = in.LogOpt
|
||||||
|
out.MaxConcurrentDownloads = in.MaxConcurrentDownloads
|
||||||
|
out.MaxConcurrentUploads = in.MaxConcurrentUploads
|
||||||
|
out.MaxDownloadAttempts = in.MaxDownloadAttempts
|
||||||
out.MetricsAddress = in.MetricsAddress
|
out.MetricsAddress = in.MetricsAddress
|
||||||
out.MTU = in.MTU
|
out.MTU = in.MTU
|
||||||
if in.Packages != nil {
|
if in.Packages != nil {
|
||||||
|
@ -3328,6 +3331,9 @@ func autoConvert_kops_DockerConfig_To_v1alpha3_DockerConfig(in *kops.DockerConfi
|
||||||
out.LogDriver = in.LogDriver
|
out.LogDriver = in.LogDriver
|
||||||
out.LogLevel = in.LogLevel
|
out.LogLevel = in.LogLevel
|
||||||
out.LogOpt = in.LogOpt
|
out.LogOpt = in.LogOpt
|
||||||
|
out.MaxConcurrentDownloads = in.MaxConcurrentDownloads
|
||||||
|
out.MaxConcurrentUploads = in.MaxConcurrentUploads
|
||||||
|
out.MaxDownloadAttempts = in.MaxDownloadAttempts
|
||||||
out.MetricsAddress = in.MetricsAddress
|
out.MetricsAddress = in.MetricsAddress
|
||||||
out.MTU = in.MTU
|
out.MTU = in.MTU
|
||||||
if in.Packages != nil {
|
if in.Packages != nil {
|
||||||
|
|
|
@ -1491,6 +1491,21 @@ func (in *DockerConfig) DeepCopyInto(out *DockerConfig) {
|
||||||
*out = make([]string, len(*in))
|
*out = make([]string, len(*in))
|
||||||
copy(*out, *in)
|
copy(*out, *in)
|
||||||
}
|
}
|
||||||
|
if in.MaxConcurrentDownloads != nil {
|
||||||
|
in, out := &in.MaxConcurrentDownloads, &out.MaxConcurrentDownloads
|
||||||
|
*out = new(int32)
|
||||||
|
**out = **in
|
||||||
|
}
|
||||||
|
if in.MaxConcurrentUploads != nil {
|
||||||
|
in, out := &in.MaxConcurrentUploads, &out.MaxConcurrentUploads
|
||||||
|
*out = new(int32)
|
||||||
|
**out = **in
|
||||||
|
}
|
||||||
|
if in.MaxDownloadAttempts != nil {
|
||||||
|
in, out := &in.MaxDownloadAttempts, &out.MaxDownloadAttempts
|
||||||
|
*out = new(int32)
|
||||||
|
**out = **in
|
||||||
|
}
|
||||||
if in.MetricsAddress != nil {
|
if in.MetricsAddress != nil {
|
||||||
in, out := &in.MetricsAddress, &out.MetricsAddress
|
in, out := &in.MetricsAddress, &out.MetricsAddress
|
||||||
*out = new(string)
|
*out = new(string)
|
||||||
|
|
|
@ -1606,6 +1606,21 @@ func (in *DockerConfig) DeepCopyInto(out *DockerConfig) {
|
||||||
*out = make([]string, len(*in))
|
*out = make([]string, len(*in))
|
||||||
copy(*out, *in)
|
copy(*out, *in)
|
||||||
}
|
}
|
||||||
|
if in.MaxConcurrentDownloads != nil {
|
||||||
|
in, out := &in.MaxConcurrentDownloads, &out.MaxConcurrentDownloads
|
||||||
|
*out = new(int32)
|
||||||
|
**out = **in
|
||||||
|
}
|
||||||
|
if in.MaxConcurrentUploads != nil {
|
||||||
|
in, out := &in.MaxConcurrentUploads, &out.MaxConcurrentUploads
|
||||||
|
*out = new(int32)
|
||||||
|
**out = **in
|
||||||
|
}
|
||||||
|
if in.MaxDownloadAttempts != nil {
|
||||||
|
in, out := &in.MaxDownloadAttempts, &out.MaxDownloadAttempts
|
||||||
|
*out = new(int32)
|
||||||
|
**out = **in
|
||||||
|
}
|
||||||
if in.MetricsAddress != nil {
|
if in.MetricsAddress != nil {
|
||||||
in, out := &in.MetricsAddress, &out.MetricsAddress
|
in, out := &in.MetricsAddress, &out.MetricsAddress
|
||||||
*out = new(string)
|
*out = new(string)
|
||||||
|
|
Loading…
Reference in New Issue