Merge pull request #3480 from jbeda/all_pflag
Convert all main binaries to pflag library
This commit is contained in:
@@ -1 +1 @@
|
|||||||
log_level: "-v=2"
|
log_level: "--v=2"
|
||||||
|
@@ -78,7 +78,7 @@ case "$1" in
|
|||||||
do_start
|
do_start
|
||||||
case "$?" in
|
case "$?" in
|
||||||
0|1) log_end_msg 0 || exit 0 ;;
|
0|1) log_end_msg 0 || exit 0 ;;
|
||||||
2) verblog_end_msg 1 || exit 1 ;;
|
2) log_end_msg 1 || exit 1 ;;
|
||||||
esac
|
esac
|
||||||
;;
|
;;
|
||||||
stop)
|
stop)
|
||||||
|
@@ -5,50 +5,50 @@
|
|||||||
|
|
||||||
{% set cloud_provider = "" -%}
|
{% set cloud_provider = "" -%}
|
||||||
{% if grains.cloud_provider is defined -%}
|
{% if grains.cloud_provider is defined -%}
|
||||||
{% set cloud_provider = "-cloud_provider=" + grains.cloud_provider -%}
|
{% set cloud_provider = "--cloud_provider=" + grains.cloud_provider -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
|
||||||
{% set address = "-address=127.0.0.1" -%}
|
{% set address = "--address=127.0.0.1" -%}
|
||||||
|
|
||||||
{% set publicAddressOverride = "" -%}
|
{% set publicAddressOverride = "" -%}
|
||||||
{% if grains.publicAddressOverride is defined -%}
|
{% if grains.publicAddressOverride is defined -%}
|
||||||
{% set publicAddressOverride = "-public_address_override=" + grains.publicAddressOverride -%}
|
{% set publicAddressOverride = "--public_address_override=" + grains.publicAddressOverride -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
|
||||||
|
|
||||||
{% if grains.etcd_servers is defined -%}
|
{% if grains.etcd_servers is defined -%}
|
||||||
{% set etcd_servers = "-etcd_servers=http://" + grains.etcd_servers + ":4001" -%}
|
{% set etcd_servers = "--etcd_servers=http://" + grains.etcd_servers + ":4001" -%}
|
||||||
{% else -%}
|
{% else -%}
|
||||||
{% set ips = salt['mine.get']('roles:kubernetes-master', 'network.ip_addrs', 'grain').values() -%}
|
{% set ips = salt['mine.get']('roles:kubernetes-master', 'network.ip_addrs', 'grain').values() -%}
|
||||||
{% set etcd_servers = "-etcd_servers=http://" + ips[0][0] + ":4001" -%}
|
{% set etcd_servers = "--etcd_servers=http://" + ips[0][0] + ":4001" -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
|
||||||
{% if grains.cloud is defined -%}
|
{% if grains.cloud is defined -%}
|
||||||
{% if grains.cloud == 'gce' -%}
|
{% if grains.cloud == 'gce' -%}
|
||||||
{% set cloud_provider = "-cloud_provider=gce" -%}
|
{% set cloud_provider = "--cloud_provider=gce" -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
|
||||||
{% if pillar['portal_net'] is defined -%}
|
{% if pillar['portal_net'] is defined -%}
|
||||||
{% set portal_net = "-portal_net=" + pillar['portal_net'] -%}
|
{% set portal_net = "--portal_net=" + pillar['portal_net'] -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
|
||||||
{% set cert_file = "-tls_cert_file=/srv/kubernetes/server.cert" -%}
|
{% set cert_file = "--tls_cert_file=/srv/kubernetes/server.cert" -%}
|
||||||
{% set key_file = "-tls_private_key_file=/srv/kubernetes/server.key" -%}
|
{% set key_file = "--tls_private_key_file=/srv/kubernetes/server.key" -%}
|
||||||
|
|
||||||
{% set secure_port = "-secure_port=6443" -%}
|
{% set secure_port = "--secure_port=6443" -%}
|
||||||
{% set token_auth_file = "-token_auth_file=/dev/null" -%}
|
{% set token_auth_file = "--token_auth_file=/dev/null" -%}
|
||||||
|
|
||||||
{% if grains.cloud is defined -%}
|
{% if grains.cloud is defined -%}
|
||||||
{% if grains.cloud == 'gce' or grains.cloud == 'vagrant' -%}
|
{% if grains.cloud == 'gce' or grains.cloud == 'vagrant' -%}
|
||||||
# TODO: generate and distribute tokens for other cloud providers.
|
# TODO: generate and distribute tokens for other cloud providers.
|
||||||
{% set token_auth_file = "-token_auth_file=/srv/kubernetes/known_tokens.csv" -%}
|
{% set token_auth_file = "--token_auth_file=/srv/kubernetes/known_tokens.csv" -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
|
||||||
{% set admission_control = "" -%}
|
{% set admission_control = "" -%}
|
||||||
{% if grains.admission_control is defined -%}
|
{% if grains.admission_control is defined -%}
|
||||||
{% set admission_control = "-admission_control=" + grains.admission_control -%}
|
{% set admission_control = "--admission_control=" + grains.admission_control -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
|
||||||
DAEMON_ARGS="{{daemon_args}} {{address}} {{etcd_servers}} {{ cloud_provider }} {{admission_control}} --allow_privileged={{pillar['allow_privileged']}} {{portal_net}} {{cert_file}} {{key_file}} {{secure_port}} {{token_auth_file}} {{publicAddressOverride}} {{pillar['log_level']}}"
|
DAEMON_ARGS="{{daemon_args}} {{address}} {{etcd_servers}} {{ cloud_provider }} {{admission_control}} --allow_privileged={{pillar['allow_privileged']}} {{portal_net}} {{cert_file}} {{key_file}} {{secure_port}} {{token_auth_file}} {{publicAddressOverride}} {{pillar['log_level']}}"
|
||||||
|
@@ -78,7 +78,7 @@ case "$1" in
|
|||||||
do_start
|
do_start
|
||||||
case "$?" in
|
case "$?" in
|
||||||
0|1) log_end_msg 0 || exit 0 ;;
|
0|1) log_end_msg 0 || exit 0 ;;
|
||||||
2) verblog_end_msg 1 || exit 1 ;;
|
2) log_end_msg 1 || exit 1 ;;
|
||||||
esac
|
esac
|
||||||
;;
|
;;
|
||||||
stop)
|
stop)
|
||||||
|
@@ -4,33 +4,33 @@
|
|||||||
{% set daemon_args = "" -%}
|
{% set daemon_args = "" -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
|
||||||
{% set master="-master=127.0.0.1:8080" -%}
|
{% set master="--master=127.0.0.1:8080" -%}
|
||||||
|
|
||||||
{% set machines = ""-%}
|
{% set machines = ""-%}
|
||||||
{% set cloud_provider = "" -%}
|
{% set cloud_provider = "" -%}
|
||||||
{% set minion_regexp = "-minion_regexp=.*" -%}
|
{% set minion_regexp = "--minion_regexp=.*" -%}
|
||||||
{% if grains.cloud_provider is defined -%}
|
{% if grains.cloud_provider is defined -%}
|
||||||
{% set cloud_provider = "-cloud_provider=" + grains.cloud_provider -%}
|
{% set cloud_provider = "--cloud_provider=" + grains.cloud_provider -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
|
||||||
{% if pillar['node_instance_prefix'] is defined -%}
|
{% if pillar['node_instance_prefix'] is defined -%}
|
||||||
{% set minion_regexp = "-minion_regexp='" + pillar['node_instance_prefix'] + ".*'" -%}
|
{% set minion_regexp = "--minion_regexp='" + pillar['node_instance_prefix'] + ".*'" -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
|
||||||
{% if grains.cloud is defined -%}
|
{% if grains.cloud is defined -%}
|
||||||
{% if grains.cloud == 'gce' -%}
|
{% if grains.cloud == 'gce' -%}
|
||||||
{% set cloud_provider = "-cloud_provider=gce" -%}
|
{% set cloud_provider = "--cloud_provider=gce" -%}
|
||||||
{% set machines = "-machines=" + ','.join(salt['mine.get']('roles:kubernetes-pool', 'network.ip_addrs', expr_form='grain').keys()) -%}
|
{% set machines = "--machines=" + ','.join(salt['mine.get']('roles:kubernetes-pool', 'network.ip_addrs', expr_form='grain').keys()) -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
{% if grains.cloud == 'aws' -%}
|
{% if grains.cloud == 'aws' -%}
|
||||||
{% set cloud_provider = "-cloud_provider=aws" -%}
|
{% set cloud_provider = "--cloud_provider=aws" -%}
|
||||||
{% set cloud_config = "-cloud_config=/etc/aws.conf" -%}
|
{% set cloud_config = "--cloud_config=/etc/aws.conf" -%}
|
||||||
{% set minion_regexp = "" -%}
|
{% set minion_regexp = "" -%}
|
||||||
{% set machines = "-machines " + ','.join(salt['mine.get']('roles:kubernetes-pool', 'network.ip_addrs', expr_form='grain').keys()) -%}
|
{% set machines = "--machines " + ','.join(salt['mine.get']('roles:kubernetes-pool', 'network.ip_addrs', expr_form='grain').keys()) -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
{% if grains.cloud == 'azure' -%}
|
{% if grains.cloud == 'azure' -%}
|
||||||
MACHINES="{{ salt['mine.get']('roles:kubernetes-pool', 'grains.items', expr_form='grain').values()|join(',', attribute='hostnamef') }}"
|
MACHINES="{{ salt['mine.get']('roles:kubernetes-pool', 'grains.items', expr_form='grain').values()|join(',', attribute='hostnamef') }}"
|
||||||
{% set machines = "-machines=$MACHINES" -%}
|
{% set machines = "--machines=$MACHINES" -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
{% if grains.cloud == 'vsphere' -%}
|
{% if grains.cloud == 'vsphere' -%}
|
||||||
# Collect IPs of minions as machines list.
|
# Collect IPs of minions as machines list.
|
||||||
@@ -42,7 +42,7 @@
|
|||||||
{% for addrs in salt['mine.get']('roles:kubernetes-pool', 'network.ip_addrs', expr_form='grain').values() -%}
|
{% for addrs in salt['mine.get']('roles:kubernetes-pool', 'network.ip_addrs', expr_form='grain').values() -%}
|
||||||
MACHINE_IPS+=( {{ addrs[0] }} )
|
MACHINE_IPS+=( {{ addrs[0] }} )
|
||||||
{% endfor -%}
|
{% endfor -%}
|
||||||
{% set machines = "-machines=$(echo ${MACHINE_IPS[@]} | xargs -n1 echo | paste -sd,)" -%}
|
{% set machines = "--machines=$(echo ${MACHINE_IPS[@]} | xargs -n1 echo | paste -sd,)" -%}
|
||||||
{% set minion_regexp = "" -%}
|
{% set minion_regexp = "" -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
@@ -80,7 +80,7 @@ case "$1" in
|
|||||||
do_start
|
do_start
|
||||||
case "$?" in
|
case "$?" in
|
||||||
0|1) log_end_msg 0 || exit 0 ;;
|
0|1) log_end_msg 0 || exit 0 ;;
|
||||||
2) verblog_end_msg 1 || exit 1 ;;
|
2) log_end_msg 1 || exit 1 ;;
|
||||||
esac
|
esac
|
||||||
;;
|
;;
|
||||||
stop)
|
stop)
|
||||||
|
@@ -3,10 +3,10 @@
|
|||||||
{% set daemon_args = "" -%}
|
{% set daemon_args = "" -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
{% if grains.api_servers is defined -%}
|
{% if grains.api_servers is defined -%}
|
||||||
{% set api_servers = "-master=http://" + grains.api_servers + ":7080" -%}
|
{% set api_servers = "--master=http://" + grains.api_servers + ":7080" -%}
|
||||||
{% else -%}
|
{% else -%}
|
||||||
{% set ips = salt['mine.get']('roles:kubernetes-master', 'network.ip_addrs', 'grain').values() -%}
|
{% set ips = salt['mine.get']('roles:kubernetes-master', 'network.ip_addrs', 'grain').values() -%}
|
||||||
{% set api_servers = "-master=http://" + ips[0][0] + ":7080" -%}
|
{% set api_servers = "--master=http://" + ips[0][0] + ":7080" -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
|
||||||
DAEMON_ARGS="{{daemon_args}} {{api_servers}} {{pillar['log_level']}}"
|
DAEMON_ARGS="{{daemon_args}} {{api_servers}} {{pillar['log_level']}}"
|
||||||
|
@@ -80,7 +80,7 @@ case "$1" in
|
|||||||
do_start
|
do_start
|
||||||
case "$?" in
|
case "$?" in
|
||||||
0|1) log_end_msg 0 || exit 0 ;;
|
0|1) log_end_msg 0 || exit 0 ;;
|
||||||
2) verblog_end_msg 1 || exit 1 ;;
|
2) log_end_msg 1 || exit 1 ;;
|
||||||
esac
|
esac
|
||||||
;;
|
;;
|
||||||
stop)
|
stop)
|
||||||
|
@@ -2,6 +2,6 @@
|
|||||||
{% if grains['os_family'] == 'RedHat' -%}
|
{% if grains['os_family'] == 'RedHat' -%}
|
||||||
{% set daemon_args = "" -%}
|
{% set daemon_args = "" -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
{% set master="-master=127.0.0.1:8080" -%}
|
{% set master="--master=127.0.0.1:8080" -%}
|
||||||
|
|
||||||
DAEMON_ARGS="{{daemon_args}} {{master}} {{pillar['log_level']}}"
|
DAEMON_ARGS="{{daemon_args}} {{master}} {{pillar['log_level']}}"
|
||||||
|
@@ -80,7 +80,7 @@ case "$1" in
|
|||||||
do_start
|
do_start
|
||||||
case "$?" in
|
case "$?" in
|
||||||
0|1) log_end_msg 0 || exit 0 ;;
|
0|1) log_end_msg 0 || exit 0 ;;
|
||||||
2) verblog_end_msg 1 || exit 1 ;;
|
2) log_end_msg 1 || exit 1 ;;
|
||||||
esac
|
esac
|
||||||
;;
|
;;
|
||||||
stop)
|
stop)
|
||||||
|
@@ -3,35 +3,35 @@
|
|||||||
{% set daemon_args = "" -%}
|
{% set daemon_args = "" -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
{% if grains.etcd_servers is defined -%}
|
{% if grains.etcd_servers is defined -%}
|
||||||
{% set etcd_servers = "-etcd_servers=http://" + grains.etcd_servers + ":4001" -%}
|
{% set etcd_servers = "--etcd_servers=http://" + grains.etcd_servers + ":4001" -%}
|
||||||
{% else -%}
|
{% else -%}
|
||||||
{% set ips = salt['mine.get']('roles:kubernetes-master', 'network.ip_addrs', 'grain').values() -%}
|
{% set ips = salt['mine.get']('roles:kubernetes-master', 'network.ip_addrs', 'grain').values() -%}
|
||||||
{% set etcd_servers = "-etcd_servers=http://" + ips[0][0] + ":4001" -%}
|
{% set etcd_servers = "--etcd_servers=http://" + ips[0][0] + ":4001" -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
|
||||||
{% if grains.apiservers is defined -%}
|
{% if grains.apiservers is defined -%}
|
||||||
{% set apiservers = "-api_servers=https://" + grains.apiservers + ":6443" -%}
|
{% set apiservers = "--api_servers=https://" + grains.apiservers + ":6443" -%}
|
||||||
{% else -%}
|
{% else -%}
|
||||||
{% set ips = salt['mine.get']('roles:kubernetes-master', 'network.ip_addrs', 'grain').values() -%}
|
{% set ips = salt['mine.get']('roles:kubernetes-master', 'network.ip_addrs', 'grain').values() -%}
|
||||||
{% set apiservers = "-api_servers=https://" + ips[0][0] + ":6443" -%}
|
{% set apiservers = "--api_servers=https://" + ips[0][0] + ":6443" -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
|
||||||
{% set address = "-address=0.0.0.0" -%}
|
{% set address = "--address=0.0.0.0" -%}
|
||||||
{% set config = "-config=/etc/kubernetes/manifests" -%}
|
{% set config = "--config=/etc/kubernetes/manifests" -%}
|
||||||
{% set hostname_override = "" -%}
|
{% set hostname_override = "" -%}
|
||||||
{% if grains.minion_ip is defined -%}
|
{% if grains.minion_ip is defined -%}
|
||||||
{% set hostname_override = " -hostname_override=" + grains.minion_ip -%}
|
{% set hostname_override = " --hostname_override=" + grains.minion_ip -%}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
|
|
||||||
{% set auth_path = "-auth_path=/var/lib/kubelet/kubernetes_auth" -%}
|
{% set auth_path = "--auth_path=/var/lib/kubelet/kubernetes_auth" -%}
|
||||||
|
|
||||||
{% set registry_qps = "-registry_qps=0.1" %}
|
{% set registry_qps = "--registry_qps=0.1" %}
|
||||||
|
|
||||||
{% set cluster_dns = "" %}
|
{% set cluster_dns = "" %}
|
||||||
{% set cluster_domain = "" %}
|
{% set cluster_domain = "" %}
|
||||||
{% if pillar['enable_cluster_dns'] is defined and pillar['enable_cluster_dns'] %}
|
{% if pillar['enable_cluster_dns'] is defined and pillar['enable_cluster_dns'] %}
|
||||||
{% set cluster_dns = "-cluster_dns=" + pillar['dns_server'] %}
|
{% set cluster_dns = "--cluster_dns=" + pillar['dns_server'] %}
|
||||||
{% set cluster_domain = "-cluster_domain=" + pillar['dns_domain'] %}
|
{% set cluster_domain = "--cluster_domain=" + pillar['dns_domain'] %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
DAEMON_ARGS="{{daemon_args}} {{etcd_servers}} {{apiservers}} {{auth_path}} {{hostname_override}} {{address}} {{config}} --allow_privileged={{pillar['allow_privileged']}} {{pillar['log_level']}} {{cluster_dns}} {{cluster_domain}}"
|
DAEMON_ARGS="{{daemon_args}} {{etcd_servers}} {{apiservers}} {{auth_path}} {{hostname_override}} {{address}} {{config}} --allow_privileged={{pillar['allow_privileged']}} {{pillar['log_level']}} {{cluster_dns}} {{cluster_domain}}"
|
||||||
|
@@ -79,7 +79,7 @@ case "$1" in
|
|||||||
do_start
|
do_start
|
||||||
case "$?" in
|
case "$?" in
|
||||||
0|1) log_end_msg 0 || exit 0 ;;
|
0|1) log_end_msg 0 || exit 0 ;;
|
||||||
2) verblog_end_msg 1 || exit 1 ;;
|
2) log_end_msg 1 || exit 1 ;;
|
||||||
esac
|
esac
|
||||||
;;
|
;;
|
||||||
stop)
|
stop)
|
||||||
|
@@ -17,7 +17,6 @@ limitations under the License.
|
|||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"flag"
|
|
||||||
"fmt"
|
"fmt"
|
||||||
"io/ioutil"
|
"io/ioutil"
|
||||||
"os"
|
"os"
|
||||||
@@ -35,6 +34,8 @@ import (
|
|||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/runtime"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/runtime"
|
||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/util"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/util"
|
||||||
"github.com/golang/glog"
|
"github.com/golang/glog"
|
||||||
|
|
||||||
|
flag "github.com/spf13/pflag"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@@ -699,7 +700,7 @@ func TestPodHasServiceEnvVars(c *client.Client) bool {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
flag.Parse()
|
util.InitFlags()
|
||||||
goruntime.GOMAXPROCS(goruntime.NumCPU())
|
goruntime.GOMAXPROCS(goruntime.NumCPU())
|
||||||
util.ReallyCrash = true
|
util.ReallyCrash = true
|
||||||
util.InitLogs()
|
util.InitLogs()
|
||||||
|
@@ -19,7 +19,6 @@ limitations under the License.
|
|||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"flag"
|
|
||||||
"io/ioutil"
|
"io/ioutil"
|
||||||
"net"
|
"net"
|
||||||
"net/http"
|
"net/http"
|
||||||
@@ -563,7 +562,7 @@ func runServiceTest(client *client.Client) {
|
|||||||
type testFunc func(*client.Client)
|
type testFunc func(*client.Client)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
flag.Parse()
|
util.InitFlags()
|
||||||
runtime.GOMAXPROCS(runtime.NumCPU())
|
runtime.GOMAXPROCS(runtime.NumCPU())
|
||||||
util.ReallyCrash = true
|
util.ReallyCrash = true
|
||||||
util.InitLogs()
|
util.InitLogs()
|
||||||
|
@@ -20,7 +20,6 @@ package main
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"crypto/tls"
|
"crypto/tls"
|
||||||
"flag"
|
|
||||||
"net"
|
"net"
|
||||||
"net/http"
|
"net/http"
|
||||||
"strconv"
|
"strconv"
|
||||||
@@ -40,6 +39,7 @@ import (
|
|||||||
|
|
||||||
"github.com/coreos/go-etcd/etcd"
|
"github.com/coreos/go-etcd/etcd"
|
||||||
"github.com/golang/glog"
|
"github.com/golang/glog"
|
||||||
|
flag "github.com/spf13/pflag"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@@ -124,7 +124,7 @@ func newEtcd(etcdConfigFile string, etcdServerList util.StringList) (helper tool
|
|||||||
}
|
}
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
flag.Parse()
|
util.InitFlags()
|
||||||
util.InitLogs()
|
util.InitLogs()
|
||||||
defer util.FlushLogs()
|
defer util.FlushLogs()
|
||||||
|
|
||||||
|
@@ -21,7 +21,6 @@ limitations under the License.
|
|||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"flag"
|
|
||||||
"net"
|
"net"
|
||||||
"net/http"
|
"net/http"
|
||||||
"strconv"
|
"strconv"
|
||||||
@@ -38,7 +37,9 @@ import (
|
|||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/service"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/service"
|
||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/util"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/util"
|
||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/version/verflag"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/version/verflag"
|
||||||
|
|
||||||
"github.com/golang/glog"
|
"github.com/golang/glog"
|
||||||
|
flag "github.com/spf13/pflag"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@@ -74,7 +75,7 @@ func verifyMinionFlags() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
flag.Parse()
|
util.InitFlags()
|
||||||
util.InitLogs()
|
util.InitLogs()
|
||||||
defer util.FlushLogs()
|
defer util.FlushLogs()
|
||||||
|
|
||||||
|
@@ -17,7 +17,6 @@ limitations under the License.
|
|||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"flag"
|
|
||||||
"net"
|
"net"
|
||||||
"net/http"
|
"net/http"
|
||||||
"strconv"
|
"strconv"
|
||||||
@@ -32,8 +31,10 @@ import (
|
|||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/util/exec"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/util/exec"
|
||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/util/iptables"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/util/iptables"
|
||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/version/verflag"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/version/verflag"
|
||||||
|
|
||||||
"github.com/coreos/go-etcd/etcd"
|
"github.com/coreos/go-etcd/etcd"
|
||||||
"github.com/golang/glog"
|
"github.com/golang/glog"
|
||||||
|
flag "github.com/spf13/pflag"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@@ -52,7 +53,7 @@ func init() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
flag.Parse()
|
util.InitFlags()
|
||||||
util.InitLogs()
|
util.InitLogs()
|
||||||
defer util.FlushLogs()
|
defer util.FlushLogs()
|
||||||
|
|
||||||
|
@@ -37,6 +37,7 @@ import (
|
|||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/util"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/util"
|
||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/version"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/version"
|
||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/version/verflag"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/version/verflag"
|
||||||
|
|
||||||
"github.com/golang/glog"
|
"github.com/golang/glog"
|
||||||
"github.com/skratchdot/open-golang/open"
|
"github.com/skratchdot/open-golang/open"
|
||||||
)
|
)
|
||||||
|
@@ -21,7 +21,6 @@ limitations under the License.
|
|||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"flag"
|
|
||||||
"math/rand"
|
"math/rand"
|
||||||
"net"
|
"net"
|
||||||
"time"
|
"time"
|
||||||
@@ -33,7 +32,9 @@ import (
|
|||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/standalone"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/standalone"
|
||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/util"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/util"
|
||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/version/verflag"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/version/verflag"
|
||||||
|
|
||||||
"github.com/golang/glog"
|
"github.com/golang/glog"
|
||||||
|
flag "github.com/spf13/pflag"
|
||||||
)
|
)
|
||||||
|
|
||||||
const defaultRootDir = "/var/lib/kubelet"
|
const defaultRootDir = "/var/lib/kubelet"
|
||||||
@@ -89,7 +90,7 @@ func setupRunOnce() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
flag.Parse()
|
util.InitFlags()
|
||||||
util.InitLogs()
|
util.InitLogs()
|
||||||
defer util.FlushLogs()
|
defer util.FlushLogs()
|
||||||
rand.Seed(time.Now().UTC().UnixNano())
|
rand.Seed(time.Now().UTC().UnixNano())
|
||||||
|
@@ -21,7 +21,6 @@ limitations under the License.
|
|||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"flag"
|
|
||||||
"fmt"
|
"fmt"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
@@ -33,6 +32,7 @@ import (
|
|||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/util"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/util"
|
||||||
|
|
||||||
"github.com/golang/glog"
|
"github.com/golang/glog"
|
||||||
|
flag "github.com/spf13/pflag"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@@ -66,7 +66,7 @@ func newApiClient(addr string, port int) *client.Client {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
flag.Parse()
|
util.InitFlags()
|
||||||
util.InitLogs()
|
util.InitLogs()
|
||||||
defer util.FlushLogs()
|
defer util.FlushLogs()
|
||||||
|
|
||||||
|
@@ -24,9 +24,9 @@ First, create your kube-apiserver.service file (change necessary variables)
|
|||||||
ExecStartPre=/usr/bin/wget -P /opt/bin https://path/to/kube-apiserver/binary
|
ExecStartPre=/usr/bin/wget -P /opt/bin https://path/to/kube-apiserver/binary
|
||||||
ExecStartPre=/usr/bin/chmod +x /opt/bin/kube-apiserver
|
ExecStartPre=/usr/bin/chmod +x /opt/bin/kube-apiserver
|
||||||
ExecStart=/opt/bin/kube-apiserver \
|
ExecStart=/opt/bin/kube-apiserver \
|
||||||
-address=0.0.0.0 \
|
--address=0.0.0.0 \
|
||||||
-port=8080 \
|
--port=8080 \
|
||||||
-etcd_servers=http://10.1.10.10:4001
|
--etcd_servers=http://10.1.10.10:4001
|
||||||
ExecStartPost=/usr/bin/etcdctl -C 10.1.10.10:4001 set /frontend:172.20.1.20 '[ "kubernetes", "http://${DEFAULT_IPV4}:8080" ]'
|
ExecStartPost=/usr/bin/etcdctl -C 10.1.10.10:4001 set /frontend:172.20.1.20 '[ "kubernetes", "http://${DEFAULT_IPV4}:8080" ]'
|
||||||
Restart=always
|
Restart=always
|
||||||
RestartSec=10
|
RestartSec=10
|
||||||
|
@@ -253,7 +253,7 @@ Congratulations!
|
|||||||
The following will run all of the end-to-end testing scenarios assuming you set your environment in cluster/kube-env.sh
|
The following will run all of the end-to-end testing scenarios assuming you set your environment in cluster/kube-env.sh
|
||||||
|
|
||||||
```
|
```
|
||||||
hack/e2e-test.sh
|
NUM_MINIONS=3 hack/e2e-test.sh
|
||||||
```
|
```
|
||||||
|
|
||||||
### Troubleshooting
|
### Troubleshooting
|
||||||
|
@@ -14,64 +14,64 @@ The **kubernetes** API server validates and configures data for 3 types of objec
|
|||||||
The the kube-apiserver several options.
|
The the kube-apiserver several options.
|
||||||
|
|
||||||
# OPTIONS
|
# OPTIONS
|
||||||
**-address**=""
|
**--address**=""
|
||||||
The address on the local server to listen to. Default 127.0.0.1
|
The address on the local server to listen to. Default 127.0.0.1
|
||||||
|
|
||||||
**-allow_privileged**=""
|
**--allow_privileged**=""
|
||||||
If true, allow privileged containers.
|
If true, allow privileged containers.
|
||||||
|
|
||||||
**-alsologtostderr**=
|
**--alsologtostderr**=
|
||||||
log to standard error as well as files. Default is false.
|
log to standard error as well as files. Default is false.
|
||||||
|
|
||||||
**-api_prefix**="/api"
|
**--api_prefix**="/api"
|
||||||
The prefix for API requests on the server. Default '/api'
|
The prefix for API requests on the server. Default '/api'
|
||||||
|
|
||||||
**-cloud_config**=""
|
**--cloud_config**=""
|
||||||
The path to the cloud provider configuration file. Empty string for no configuration file.
|
The path to the cloud provider configuration file. Empty string for no configuration file.
|
||||||
|
|
||||||
**-cloud_provider**=""
|
**--cloud_provider**=""
|
||||||
The provider for cloud services. Empty string for no provider.
|
The provider for cloud services. Empty string for no provider.
|
||||||
|
|
||||||
**-cors_allowed_origins**=[]
|
**--cors_allowed_origins**=[]
|
||||||
List of allowed origins for CORS, comma separated. An allowed origin can be a regular expression to support subdomain matching. If this list is empty CORS will not be enabled.
|
List of allowed origins for CORS, comma separated. An allowed origin can be a regular expression to support subdomain matching. If this list is empty CORS will not be enabled.
|
||||||
|
|
||||||
**-etcd_servers**=[]
|
**--etcd_servers**=[]
|
||||||
List of etcd servers to watch (http://ip:port), comma separated
|
List of etcd servers to watch (http://ip:port), comma separated
|
||||||
|
|
||||||
**-health_check_minions**=
|
**--health_check_minions**=
|
||||||
If true, health check minions and filter unhealthy ones. Default true.
|
If true, health check minions and filter unhealthy ones. Default true.
|
||||||
|
|
||||||
**-log_backtrace_at=**:0
|
**--log_backtrace_at=**:0
|
||||||
when logging hits line file:N, emit a stack trace
|
when logging hits line file:N, emit a stack trace
|
||||||
|
|
||||||
**-log_dir**=""
|
**--log_dir**=""
|
||||||
If non-empty, write log files in this directory
|
If non-empty, write log files in this directory
|
||||||
|
|
||||||
**-log_flush_frequency**=5s
|
**--log_flush_frequency**=5s
|
||||||
Maximum number of seconds between log flushes. Default is 5 seconds.
|
Maximum number of seconds between log flushes. Default is 5 seconds.
|
||||||
|
|
||||||
**-logtostderr**=
|
**--logtostderr**=
|
||||||
log to standard error instead of files. Default is false.
|
log to standard error instead of files. Default is false.
|
||||||
|
|
||||||
**-kubelet_port**=10250
|
**--kubelet_port**=10250
|
||||||
The port at which kubelet will be listening on the minions. Default is 10250.
|
The port at which kubelet will be listening on the minions. Default is 10250.
|
||||||
|
|
||||||
**-port**=8080
|
**--port**=8080
|
||||||
The port to listen on. Default is 8080.
|
The port to listen on. Default is 8080.
|
||||||
|
|
||||||
**-stderrthreshold**=0
|
**--stderrthreshold**=0
|
||||||
logs at or above this threshold go to stderr. Default is 0.
|
logs at or above this threshold go to stderr. Default is 0.
|
||||||
|
|
||||||
**-storage_version**=""
|
**--storage_version**=""
|
||||||
The version to store resources with. Defaults to server preferred.
|
The version to store resources with. Defaults to server preferred.
|
||||||
|
|
||||||
**-v**=0
|
**--v**=0
|
||||||
Log level for V logs.
|
Log level for V logs.
|
||||||
|
|
||||||
**-version**=false
|
**--version**=false
|
||||||
Print version information and quit. Default is false.
|
Print version information and quit. Default is false.
|
||||||
|
|
||||||
**-vmodule**=
|
**--vmodule**=
|
||||||
comma-separated list of pattern=N settings for file-filtered logging
|
comma-separated list of pattern=N settings for file-filtered logging
|
||||||
|
|
||||||
# EXAMPLES
|
# EXAMPLES
|
||||||
|
@@ -14,64 +14,64 @@ The **kubernetes** controller manager is really a service that is layered on top
|
|||||||
The kube-controller-manager has several options.
|
The kube-controller-manager has several options.
|
||||||
|
|
||||||
# OPTIONS
|
# OPTIONS
|
||||||
**-address**=""
|
**--address**=""
|
||||||
The address on the local server to listen to. Default 127.0.0.1.
|
The address on the local server to listen to. Default 127.0.0.1.
|
||||||
|
|
||||||
**-allow_privileged**="false"
|
**--allow_privileged**="false"
|
||||||
If true, allow privileged containers.
|
If true, allow privileged containers.
|
||||||
|
|
||||||
**-address=**"127.0.0.1"
|
**--address=**"127.0.0.1"
|
||||||
The address to serve from.
|
The address to serve from.
|
||||||
|
|
||||||
**-alsologtostderr**=false
|
**--alsologtostderr**=false
|
||||||
log to standard error as well as files.
|
log to standard error as well as files.
|
||||||
|
|
||||||
**-api_version**=""
|
**--api_version**=""
|
||||||
The API version to use when talking to the server.
|
The API version to use when talking to the server.
|
||||||
|
|
||||||
**-cloud_config**=""
|
**--cloud_config**=""
|
||||||
The path to the cloud provider configuration file. Empty string for no configuration file.
|
The path to the cloud provider configuration file. Empty string for no configuration file.
|
||||||
|
|
||||||
**-cloud_provider**=""
|
**--cloud_provider**=""
|
||||||
The provider for cloud services. Empty string for no provider.
|
The provider for cloud services. Empty string for no provider.
|
||||||
|
|
||||||
**-minion_regexp**=""
|
**--minion_regexp**=""
|
||||||
If non empty, and -cloud_provider is specified, a regular expression for matching minion VMs.
|
If non empty, and -cloud_provider is specified, a regular expression for matching minion VMs.
|
||||||
|
|
||||||
**-insecure_skip_tls_verify**=false
|
**--insecure_skip_tls_verify**=false
|
||||||
If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure.
|
If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure.
|
||||||
|
|
||||||
**-log_backtrace_at**=:0
|
**--log_backtrace_at**=:0
|
||||||
when logging hits line file:N, emit a stack trace.
|
when logging hits line file:N, emit a stack trace.
|
||||||
|
|
||||||
**-log_dir**=""
|
**--log_dir**=""
|
||||||
If non-empty, write log files in this directory.
|
If non-empty, write log files in this directory.
|
||||||
|
|
||||||
**-log_flush_frequency**=5s
|
**--log_flush_frequency**=5s
|
||||||
Maximum number of seconds between log flushes.
|
Maximum number of seconds between log flushes.
|
||||||
|
|
||||||
**-logtostderr**=false
|
**--logtostderr**=false
|
||||||
log to standard error instead of files.
|
log to standard error instead of files.
|
||||||
|
|
||||||
**-machines**=[]
|
**--machines**=[]
|
||||||
List of machines to schedule onto, comma separated.
|
List of machines to schedule onto, comma separated.
|
||||||
|
|
||||||
**-master**=""
|
**--master**=""
|
||||||
The address of the Kubernetes API server.
|
The address of the Kubernetes API server.
|
||||||
|
|
||||||
**-port**=10252
|
**--port**=10252
|
||||||
The port that the controller-manager's http service runs on.
|
The port that the controller-manager's http service runs on.
|
||||||
|
|
||||||
**-stderrthreshold**=0
|
**--stderrthreshold**=0
|
||||||
logs at or above this threshold go to stderr.
|
logs at or above this threshold go to stderr.
|
||||||
|
|
||||||
**-v**=0
|
**--v**=0
|
||||||
log level for V logs.
|
log level for V logs.
|
||||||
|
|
||||||
**-version**=false
|
**--version**=false
|
||||||
Print version information and quit.
|
Print version information and quit.
|
||||||
|
|
||||||
**-vmodule**=
|
**--vmodule**=
|
||||||
comma-separated list of pattern=N settings for file-filtered logging.
|
comma-separated list of pattern=N settings for file-filtered logging.
|
||||||
|
|
||||||
# EXAMPLES
|
# EXAMPLES
|
||||||
|
@@ -14,46 +14,46 @@ The **kubernetes** network proxy runs on each node. This reflects services as de
|
|||||||
The kube-proxy takes several options.
|
The kube-proxy takes several options.
|
||||||
|
|
||||||
# OPTIONS
|
# OPTIONS
|
||||||
**-alsologtostderr**=false
|
**--alsologtostderr**=false
|
||||||
log to standard error as well as files
|
log to standard error as well as files
|
||||||
|
|
||||||
**-api_version=**""
|
**--api_version=**""
|
||||||
The API version to use when talking to the server
|
The API version to use when talking to the server
|
||||||
|
|
||||||
**-bindaddress**="0.0.0.0"
|
**--bindaddress**="0.0.0.0"
|
||||||
The address for the proxy server to serve on (set to 0.0.0.0 or "" for all interfaces)
|
The address for the proxy server to serve on (set to 0.0.0.0 or "" for all interfaces)
|
||||||
|
|
||||||
**-etcd_servers**=[]
|
**--etcd_servers**=[]
|
||||||
List of etcd servers to watch (http://ip:port), comma separated (optional)
|
List of etcd servers to watch (http://ip:port), comma separated (optional)
|
||||||
|
|
||||||
**-insecure_skip_tls_verify**=false
|
**--insecure_skip_tls_verify**=false
|
||||||
If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure.
|
If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure.
|
||||||
|
|
||||||
**-log_backtrace_at**=:0
|
**--log_backtrace_at**=:0
|
||||||
when logging hits line file:N, emit a stack trace
|
when logging hits line file:N, emit a stack trace
|
||||||
|
|
||||||
**-log_dir**=""
|
**--log_dir**=""
|
||||||
If non-empty, write log files in this directory
|
If non-empty, write log files in this directory
|
||||||
|
|
||||||
**-log_flush_frequency**=5s
|
**--log_flush_frequency**=5s
|
||||||
Maximum number of seconds between log flushes
|
Maximum number of seconds between log flushes
|
||||||
|
|
||||||
**-logtostderr**=false
|
**--logtostderr**=false
|
||||||
log to standard error instead of files
|
log to standard error instead of files
|
||||||
|
|
||||||
**-master**=""
|
**--master**=""
|
||||||
The address of the Kubernetes API server
|
The address of the Kubernetes API server
|
||||||
|
|
||||||
**-stderrthreshold**=0
|
**--stderrthreshold**=0
|
||||||
logs at or above this threshold go to stderr
|
logs at or above this threshold go to stderr
|
||||||
|
|
||||||
**-v**=0
|
**--v**=0
|
||||||
log level for V logs
|
log level for V logs
|
||||||
|
|
||||||
**-version**=false
|
**--version**=false
|
||||||
Print version information and quit
|
Print version information and quit
|
||||||
|
|
||||||
**-vmodule**=
|
**--vmodule**=
|
||||||
comma-separated list of pattern=N settings for file-filtered logging
|
comma-separated list of pattern=N settings for file-filtered logging
|
||||||
|
|
||||||
|
|
||||||
|
@@ -14,46 +14,46 @@ The **kubernetes** scheduler is a policy-rich, topology-aware, workload-specific
|
|||||||
The kube-scheduler can take several options.
|
The kube-scheduler can take several options.
|
||||||
|
|
||||||
# OPTIONS
|
# OPTIONS
|
||||||
**-address=**"127.0.0.1"
|
**--address=**"127.0.0.1"
|
||||||
The address to serve from.
|
The address to serve from.
|
||||||
|
|
||||||
**-alsologtostderr=**false
|
**--alsologtostderr=**false
|
||||||
log to standard error as well as files.
|
log to standard error as well as files.
|
||||||
|
|
||||||
**-api_version=**""
|
**--api_version=**""
|
||||||
The API version to use when talking to the server.
|
The API version to use when talking to the server.
|
||||||
|
|
||||||
**-insecure_skip_tls_verify**=false
|
**--insecure_skip_tls_verify**=false
|
||||||
If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure.
|
If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure.
|
||||||
|
|
||||||
**-log_backtrace_at=**:0
|
**--log_backtrace_at=**:0
|
||||||
when logging hits line file:N, emit a stack trace.
|
when logging hits line file:N, emit a stack trace.
|
||||||
|
|
||||||
**-log_dir=**""
|
**--log_dir=**""
|
||||||
If non-empty, write log files in this directory.
|
If non-empty, write log files in this directory.
|
||||||
|
|
||||||
**-log_flush_frequency**=5s
|
**--log_flush_frequency**=5s
|
||||||
Maximum number of seconds between log flushes.
|
Maximum number of seconds between log flushes.
|
||||||
|
|
||||||
**-logtostderr**=false
|
**--logtostderr**=false
|
||||||
log to standard error instead of files.
|
log to standard error instead of files.
|
||||||
|
|
||||||
**-master=**""
|
**--master=**""
|
||||||
The address of the Kubernetes API server.
|
The address of the Kubernetes API server.
|
||||||
|
|
||||||
**-port=**10251
|
**--port=**10251
|
||||||
The port that the scheduler's http service runs on.
|
The port that the scheduler's http service runs on.
|
||||||
|
|
||||||
**-stderrthreshold**=0
|
**--stderrthreshold**=0
|
||||||
logs at or above this threshold go to stderr.
|
logs at or above this threshold go to stderr.
|
||||||
|
|
||||||
**-v**=0
|
**--v**=0
|
||||||
log level for V logs.
|
log level for V logs.
|
||||||
|
|
||||||
**-version**=false
|
**--version**=false
|
||||||
Print version information and quit.
|
Print version information and quit.
|
||||||
|
|
||||||
**-vmodule**=
|
**--vmodule**=
|
||||||
comma-separated list of pattern=N settings for file-filtered logging.
|
comma-separated list of pattern=N settings for file-filtered logging.
|
||||||
|
|
||||||
# EXAMPLES
|
# EXAMPLES
|
||||||
|
@@ -20,79 +20,79 @@ There are 4 ways that a container manifest can be provided to the Kubelet:
|
|||||||
|
|
||||||
|
|
||||||
# OPTIONS
|
# OPTIONS
|
||||||
**-address**="127.0.0.1"
|
**--address**="127.0.0.1"
|
||||||
The address for the info server to serve on (set to 0.0.0.0 or "" for all interfaces).
|
The address for the info server to serve on (set to 0.0.0.0 or "" for all interfaces).
|
||||||
|
|
||||||
**-allow_privileged**=false
|
**--allow_privileged**=false
|
||||||
If true, allow containers to request privileged mode. [default=false].
|
If true, allow containers to request privileged mode. [default=false].
|
||||||
|
|
||||||
**-alsologtostderr**=false
|
**--alsologtostderr**=false
|
||||||
log to standard error as well as files.
|
log to standard error as well as files.
|
||||||
|
|
||||||
**-config**=""
|
**--config**=""
|
||||||
Path to the config file or directory of files.
|
Path to the config file or directory of files.
|
||||||
|
|
||||||
**-docker_endpoint**=""
|
**--docker_endpoint**=""
|
||||||
If non-empty, use this for the docker endpoint to communicate with.
|
If non-empty, use this for the docker endpoint to communicate with.
|
||||||
|
|
||||||
**-enable_server**=true
|
**--enable_server**=true
|
||||||
Enable the info server.
|
Enable the info server.
|
||||||
|
|
||||||
**-etcd_servers**=[]
|
**--etcd_servers**=[]
|
||||||
List of etcd servers to watch (http://ip:port), comma separated.
|
List of etcd servers to watch (http://ip:port), comma separated.
|
||||||
|
|
||||||
**-file_check_frequency**=20s
|
**--file_check_frequency**=20s
|
||||||
Duration between checking config files for new data.
|
Duration between checking config files for new data.
|
||||||
|
|
||||||
**-hostname_override**=""
|
**--hostname_override**=""
|
||||||
If non-empty, will use this string as identification instead of the actual hostname.
|
If non-empty, will use this string as identification instead of the actual hostname.
|
||||||
|
|
||||||
**-http_check_frequency**=20s
|
**--http_check_frequency**=20s
|
||||||
Duration between checking http for new data.
|
Duration between checking http for new data.
|
||||||
|
|
||||||
**-log_backtrace_at**=:0
|
**--log_backtrace_at**=:0
|
||||||
when logging hits line file:N, emit a stack trace.
|
when logging hits line file:N, emit a stack trace.
|
||||||
|
|
||||||
**-log_dir**=""
|
**--log_dir**=""
|
||||||
If non-empty, write log files in this directory.
|
If non-empty, write log files in this directory.
|
||||||
|
|
||||||
**-log_flush_frequency**=5s
|
**--log_flush_frequency**=5s
|
||||||
Maximum number of seconds between log flushes.
|
Maximum number of seconds between log flushes.
|
||||||
|
|
||||||
**-logtostderr**=false
|
**--logtostderr**=false
|
||||||
log to standard error instead of files.
|
log to standard error instead of files.
|
||||||
|
|
||||||
**-manifest_url**=""
|
**--manifest_url**=""
|
||||||
URL for accessing the container manifest.
|
URL for accessing the container manifest.
|
||||||
|
|
||||||
**-network_container_image**="kubernetes/pause:latest"
|
**--network_container_image**="kubernetes/pause:latest"
|
||||||
The image that network containers in each pod will use.
|
The image that network containers in each pod will use.
|
||||||
|
|
||||||
**-port**=10250
|
**--port**=10250
|
||||||
The port for the info server to serve on.
|
The port for the info server to serve on.
|
||||||
|
|
||||||
**-registry_burst**=10
|
**--registry_burst**=10
|
||||||
Maximum size of a bursty pulls, temporarily allows pulls to burst to this number, while still not exceeding registry_qps. Only used if --registry_qps > 0.
|
Maximum size of a bursty pulls, temporarily allows pulls to burst to this number, while still not exceeding registry_qps. Only used if --registry_qps > 0.
|
||||||
|
|
||||||
**-registry_qps**=0
|
**--registry_qps**=0
|
||||||
If > 0, limit registry pull QPS to this value. If 0, unlimited. [default=0.0].
|
If > 0, limit registry pull QPS to this value. If 0, unlimited. [default=0.0].
|
||||||
|
|
||||||
**-root_dir**="/var/lib/kubelet"
|
**--root_dir**="/var/lib/kubelet"
|
||||||
Directory path for managing kubelet files (volume mounts,etc).
|
Directory path for managing kubelet files (volume mounts,etc).
|
||||||
|
|
||||||
**-stderrthreshold**=0
|
**--stderrthreshold**=0
|
||||||
logs at or above this threshold go to stderr.
|
logs at or above this threshold go to stderr.
|
||||||
|
|
||||||
**-sync_frequency**=10s
|
**--sync_frequency**=10s
|
||||||
Max period between synchronizing running containers and config.
|
Max period between synchronizing running containers and config.
|
||||||
|
|
||||||
**-v**=0
|
**--v**=0
|
||||||
log level for V logs.
|
log level for V logs.
|
||||||
|
|
||||||
**-version**=false
|
**--version**=false
|
||||||
Print version information and quit.
|
Print version information and quit.
|
||||||
|
|
||||||
**-vmodule**=
|
**--vmodule**=
|
||||||
comma-separated list of pattern=N settings for file-filtered logging.
|
comma-separated list of pattern=N settings for file-filtered logging.
|
||||||
|
|
||||||
|
|
||||||
|
@@ -17,84 +17,84 @@ The the kube\-apiserver several options.
|
|||||||
|
|
||||||
.SH OPTIONS
|
.SH OPTIONS
|
||||||
.PP
|
.PP
|
||||||
\fB\-address\fP=""
|
\fB\-\-address\fP=""
|
||||||
The address on the local server to listen to. Default 127.0.0.1
|
The address on the local server to listen to. Default 127.0.0.1
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-allow\_privileged\fP=""
|
\fB\-\-allow\_privileged\fP=""
|
||||||
If true, allow privileged containers.
|
If true, allow privileged containers.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-alsologtostderr\fP=
|
\fB\-\-alsologtostderr\fP=
|
||||||
log to standard error as well as files. Default is false.
|
log to standard error as well as files. Default is false.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-api\_prefix\fP="/api"
|
\fB\-\-api\_prefix\fP="/api"
|
||||||
The prefix for API requests on the server. Default '/api'
|
The prefix for API requests on the server. Default '/api'
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-cloud\_config\fP=""
|
\fB\-\-cloud\_config\fP=""
|
||||||
The path to the cloud provider configuration file. Empty string for no configuration file.
|
The path to the cloud provider configuration file. Empty string for no configuration file.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-cloud\_provider\fP=""
|
\fB\-\-cloud\_provider\fP=""
|
||||||
The provider for cloud services. Empty string for no provider.
|
The provider for cloud services. Empty string for no provider.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-cors\_allowed\_origins\fP=[]
|
\fB\-\-cors\_allowed\_origins\fP=[]
|
||||||
List of allowed origins for CORS, comma separated. An allowed origin can be a regular expression to support subdomain matching. If this list is empty CORS will not be enabled.
|
List of allowed origins for CORS, comma separated. An allowed origin can be a regular expression to support subdomain matching. If this list is empty CORS will not be enabled.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-etcd\_servers\fP=[]
|
\fB\-\-etcd\_servers\fP=[]
|
||||||
List of etcd servers to watch (
|
List of etcd servers to watch (
|
||||||
\[la]http://ip:port\[ra]), comma separated
|
\[la]http://ip:port\[ra]), comma separated
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-health\_check\_minions\fP=
|
\fB\-\-health\_check\_minions\fP=
|
||||||
If true, health check minions and filter unhealthy ones. Default true.
|
If true, health check minions and filter unhealthy ones. Default true.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_backtrace\_at=\fP:0
|
\fB\-\-log\_backtrace\_at=\fP:0
|
||||||
when logging hits line file:N, emit a stack trace
|
when logging hits line file:N, emit a stack trace
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_dir\fP=""
|
\fB\-\-log\_dir\fP=""
|
||||||
If non\-empty, write log files in this directory
|
If non\-empty, write log files in this directory
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_flush\_frequency\fP=5s
|
\fB\-\-log\_flush\_frequency\fP=5s
|
||||||
Maximum number of seconds between log flushes. Default is 5 seconds.
|
Maximum number of seconds between log flushes. Default is 5 seconds.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-logtostderr\fP=
|
\fB\-\-logtostderr\fP=
|
||||||
log to standard error instead of files. Default is false.
|
log to standard error instead of files. Default is false.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-kubelet\_port\fP=10250
|
\fB\-\-kubelet\_port\fP=10250
|
||||||
The port at which kubelet will be listening on the minions. Default is 10250.
|
The port at which kubelet will be listening on the minions. Default is 10250.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-port\fP=8080
|
\fB\-\-port\fP=8080
|
||||||
The port to listen on. Default is 8080.
|
The port to listen on. Default is 8080.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-stderrthreshold\fP=0
|
\fB\-\-stderrthreshold\fP=0
|
||||||
logs at or above this threshold go to stderr. Default is 0.
|
logs at or above this threshold go to stderr. Default is 0.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-storage\_version\fP=""
|
\fB\-\-storage\_version\fP=""
|
||||||
The version to store resources with. Defaults to server preferred.
|
The version to store resources with. Defaults to server preferred.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-v\fP=0
|
\fB\-\-v\fP=0
|
||||||
Log level for V logs.
|
Log level for V logs.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-version\fP=false
|
\fB\-\-version\fP=false
|
||||||
Print version information and quit. Default is false.
|
Print version information and quit. Default is false.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-vmodule\fP=
|
\fB\-\-vmodule\fP=
|
||||||
comma\-separated list of pattern=N settings for file\-filtered logging
|
comma\-separated list of pattern=N settings for file\-filtered logging
|
||||||
|
|
||||||
.SH EXAMPLES
|
.SH EXAMPLES
|
||||||
@@ -102,7 +102,7 @@ The the kube\-apiserver several options.
|
|||||||
.RS
|
.RS
|
||||||
|
|
||||||
.nf
|
.nf
|
||||||
/usr/bin/kube\-apiserver \-\-logtostderr=true \-\-v=0 \-\-etcd\_servers=http://127.0.0.1:4001 \-\-address=0.0.0.0 \-\-port=8080 \-\-machines=127.0.0.1 \-\-kubelet\_port=10250 \-\-allow\_privileged=false
|
/usr/bin/kube\-apiserver \-\-logtostderr=true \-\-v=0 \-\-etcd\_servers=http://127.0.0.1:4001 \-\-address=0.0.0.0 \-\-port=8080 \-\-kubelet\_port=10250 \-\-allow\_privileged=false
|
||||||
|
|
||||||
.fi
|
.fi
|
||||||
|
|
||||||
|
@@ -17,83 +17,83 @@ The kube\-controller\-manager has several options.
|
|||||||
|
|
||||||
.SH OPTIONS
|
.SH OPTIONS
|
||||||
.PP
|
.PP
|
||||||
\fB\-address\fP=""
|
\fB\-\-address\fP=""
|
||||||
The address on the local server to listen to. Default 127.0.0.1.
|
The address on the local server to listen to. Default 127.0.0.1.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-allow\_privileged\fP="false"
|
\fB\-\-allow\_privileged\fP="false"
|
||||||
If true, allow privileged containers.
|
If true, allow privileged containers.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-address=\fP"127.0.0.1"
|
\fB\-\-address=\fP"127.0.0.1"
|
||||||
The address to serve from.
|
The address to serve from.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-alsologtostderr\fP=false
|
\fB\-\-alsologtostderr\fP=false
|
||||||
log to standard error as well as files.
|
log to standard error as well as files.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-api\_version\fP=""
|
\fB\-\-api\_version\fP=""
|
||||||
The API version to use when talking to the server.
|
The API version to use when talking to the server.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-cloud\_config\fP=""
|
\fB\-\-cloud\_config\fP=""
|
||||||
The path to the cloud provider configuration file. Empty string for no configuration file.
|
The path to the cloud provider configuration file. Empty string for no configuration file.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-cloud\_provider\fP=""
|
\fB\-\-cloud\_provider\fP=""
|
||||||
The provider for cloud services. Empty string for no provider.
|
The provider for cloud services. Empty string for no provider.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-minion\_regexp\fP=""
|
\fB\-\-minion\_regexp\fP=""
|
||||||
If non empty, and \-cloud\_provider is specified, a regular expression for matching minion VMs.
|
If non empty, and \-cloud\_provider is specified, a regular expression for matching minion VMs.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-insecure\_skip\_tls\_verify\fP=false
|
\fB\-\-insecure\_skip\_tls\_verify\fP=false
|
||||||
If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure.
|
If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_backtrace\_at\fP=:0
|
\fB\-\-log\_backtrace\_at\fP=:0
|
||||||
when logging hits line file:N, emit a stack trace.
|
when logging hits line file:N, emit a stack trace.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_dir\fP=""
|
\fB\-\-log\_dir\fP=""
|
||||||
If non\-empty, write log files in this directory.
|
If non\-empty, write log files in this directory.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_flush\_frequency\fP=5s
|
\fB\-\-log\_flush\_frequency\fP=5s
|
||||||
Maximum number of seconds between log flushes.
|
Maximum number of seconds between log flushes.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-logtostderr\fP=false
|
\fB\-\-logtostderr\fP=false
|
||||||
log to standard error instead of files.
|
log to standard error instead of files.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-machines\fP=[]
|
\fB\-\-machines\fP=[]
|
||||||
List of machines to schedule onto, comma separated.
|
List of machines to schedule onto, comma separated.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-master\fP=""
|
\fB\-\-master\fP=""
|
||||||
The address of the Kubernetes API server.
|
The address of the Kubernetes API server.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-port\fP=10252
|
\fB\-\-port\fP=10252
|
||||||
The port that the controller\-manager's http service runs on.
|
The port that the controller\-manager's http service runs on.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-stderrthreshold\fP=0
|
\fB\-\-stderrthreshold\fP=0
|
||||||
logs at or above this threshold go to stderr.
|
logs at or above this threshold go to stderr.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-v\fP=0
|
\fB\-\-v\fP=0
|
||||||
log level for V logs.
|
log level for V logs.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-version\fP=false
|
\fB\-\-version\fP=false
|
||||||
Print version information and quit.
|
Print version information and quit.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-vmodule\fP=
|
\fB\-\-vmodule\fP=
|
||||||
comma\-separated list of pattern=N settings for file\-filtered logging.
|
comma\-separated list of pattern=N settings for file\-filtered logging.
|
||||||
|
|
||||||
.SH EXAMPLES
|
.SH EXAMPLES
|
||||||
|
@@ -17,60 +17,60 @@ The kube\-proxy takes several options.
|
|||||||
|
|
||||||
.SH OPTIONS
|
.SH OPTIONS
|
||||||
.PP
|
.PP
|
||||||
\fB\-alsologtostderr\fP=false
|
\fB\-\-alsologtostderr\fP=false
|
||||||
log to standard error as well as files
|
log to standard error as well as files
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-api\_version=\fP""
|
\fB\-\-api\_version=\fP""
|
||||||
The API version to use when talking to the server
|
The API version to use when talking to the server
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-bindaddress\fP="0.0.0.0"
|
\fB\-\-bindaddress\fP="0.0.0.0"
|
||||||
The address for the proxy server to serve on (set to 0.0.0.0 or "" for all interfaces)
|
The address for the proxy server to serve on (set to 0.0.0.0 or "" for all interfaces)
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-etcd\_servers\fP=[]
|
\fB\-\-etcd\_servers\fP=[]
|
||||||
List of etcd servers to watch (
|
List of etcd servers to watch (
|
||||||
\[la]http://ip:port\[ra]), comma separated (optional)
|
\[la]http://ip:port\[ra]), comma separated (optional)
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-insecure\_skip\_tls\_verify\fP=false
|
\fB\-\-insecure\_skip\_tls\_verify\fP=false
|
||||||
If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure.
|
If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_backtrace\_at\fP=:0
|
\fB\-\-log\_backtrace\_at\fP=:0
|
||||||
when logging hits line file:N, emit a stack trace
|
when logging hits line file:N, emit a stack trace
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_dir\fP=""
|
\fB\-\-log\_dir\fP=""
|
||||||
If non\-empty, write log files in this directory
|
If non\-empty, write log files in this directory
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_flush\_frequency\fP=5s
|
\fB\-\-log\_flush\_frequency\fP=5s
|
||||||
Maximum number of seconds between log flushes
|
Maximum number of seconds between log flushes
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-logtostderr\fP=false
|
\fB\-\-logtostderr\fP=false
|
||||||
log to standard error instead of files
|
log to standard error instead of files
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-master\fP=""
|
\fB\-\-master\fP=""
|
||||||
The address of the Kubernetes API server
|
The address of the Kubernetes API server
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-stderrthreshold\fP=0
|
\fB\-\-stderrthreshold\fP=0
|
||||||
logs at or above this threshold go to stderr
|
logs at or above this threshold go to stderr
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-v\fP=0
|
\fB\-\-v\fP=0
|
||||||
log level for V logs
|
log level for V logs
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-version\fP=false
|
\fB\-\-version\fP=false
|
||||||
Print version information and quit
|
Print version information and quit
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-vmodule\fP=
|
\fB\-\-vmodule\fP=
|
||||||
comma\-separated list of pattern=N settings for file\-filtered logging
|
comma\-separated list of pattern=N settings for file\-filtered logging
|
||||||
|
|
||||||
.SH EXAMPLES
|
.SH EXAMPLES
|
||||||
|
@@ -17,59 +17,59 @@ The kube\-scheduler can take several options.
|
|||||||
|
|
||||||
.SH OPTIONS
|
.SH OPTIONS
|
||||||
.PP
|
.PP
|
||||||
\fB\-address=\fP"127.0.0.1"
|
\fB\-\-address=\fP"127.0.0.1"
|
||||||
The address to serve from.
|
The address to serve from.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-alsologtostderr=\fPfalse
|
\fB\-\-alsologtostderr=\fPfalse
|
||||||
log to standard error as well as files.
|
log to standard error as well as files.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-api\_version=\fP""
|
\fB\-\-api\_version=\fP""
|
||||||
The API version to use when talking to the server.
|
The API version to use when talking to the server.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-insecure\_skip\_tls\_verify\fP=false
|
\fB\-\-insecure\_skip\_tls\_verify\fP=false
|
||||||
If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure.
|
If true, the server's certificate will not be checked for validity. This will make your HTTPS connections insecure.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_backtrace\_at=\fP:0
|
\fB\-\-log\_backtrace\_at=\fP:0
|
||||||
when logging hits line file:N, emit a stack trace.
|
when logging hits line file:N, emit a stack trace.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_dir=\fP""
|
\fB\-\-log\_dir=\fP""
|
||||||
If non\-empty, write log files in this directory.
|
If non\-empty, write log files in this directory.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_flush\_frequency\fP=5s
|
\fB\-\-log\_flush\_frequency\fP=5s
|
||||||
Maximum number of seconds between log flushes.
|
Maximum number of seconds between log flushes.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-logtostderr\fP=false
|
\fB\-\-logtostderr\fP=false
|
||||||
log to standard error instead of files.
|
log to standard error instead of files.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-master=\fP""
|
\fB\-\-master=\fP""
|
||||||
The address of the Kubernetes API server.
|
The address of the Kubernetes API server.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-port=\fP10251
|
\fB\-\-port=\fP10251
|
||||||
The port that the scheduler's http service runs on.
|
The port that the scheduler's http service runs on.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-stderrthreshold\fP=0
|
\fB\-\-stderrthreshold\fP=0
|
||||||
logs at or above this threshold go to stderr.
|
logs at or above this threshold go to stderr.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-v\fP=0
|
\fB\-\-v\fP=0
|
||||||
log level for V logs.
|
log level for V logs.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-version\fP=false
|
\fB\-\-version\fP=false
|
||||||
Print version information and quit.
|
Print version information and quit.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-vmodule\fP=
|
\fB\-\-vmodule\fP=
|
||||||
comma\-separated list of pattern=N settings for file\-filtered logging.
|
comma\-separated list of pattern=N settings for file\-filtered logging.
|
||||||
|
|
||||||
.SH EXAMPLES
|
.SH EXAMPLES
|
||||||
|
@@ -28,104 +28,104 @@ HTTP server The kubelet can also listen for HTTP and respond to a simple API (un
|
|||||||
|
|
||||||
.SH OPTIONS
|
.SH OPTIONS
|
||||||
.PP
|
.PP
|
||||||
\fB\-address\fP="127.0.0.1"
|
\fB\-\-address\fP="127.0.0.1"
|
||||||
The address for the info server to serve on (set to 0.0.0.0 or "" for all interfaces).
|
The address for the info server to serve on (set to 0.0.0.0 or "" for all interfaces).
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-allow\_privileged\fP=false
|
\fB\-\-allow\_privileged\fP=false
|
||||||
If true, allow containers to request privileged mode. [default=false].
|
If true, allow containers to request privileged mode. [default=false].
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-alsologtostderr\fP=false
|
\fB\-\-alsologtostderr\fP=false
|
||||||
log to standard error as well as files.
|
log to standard error as well as files.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-config\fP=""
|
\fB\-\-config\fP=""
|
||||||
Path to the config file or directory of files.
|
Path to the config file or directory of files.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-docker\_endpoint\fP=""
|
\fB\-\-docker\_endpoint\fP=""
|
||||||
If non\-empty, use this for the docker endpoint to communicate with.
|
If non\-empty, use this for the docker endpoint to communicate with.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-enable\_server\fP=true
|
\fB\-\-enable\_server\fP=true
|
||||||
Enable the info server.
|
Enable the info server.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-etcd\_servers\fP=[]
|
\fB\-\-etcd\_servers\fP=[]
|
||||||
List of etcd servers to watch (
|
List of etcd servers to watch (
|
||||||
\[la]http://ip:port\[ra]), comma separated.
|
\[la]http://ip:port\[ra]), comma separated.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-file\_check\_frequency\fP=20s
|
\fB\-\-file\_check\_frequency\fP=20s
|
||||||
Duration between checking config files for new data.
|
Duration between checking config files for new data.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-hostname\_override\fP=""
|
\fB\-\-hostname\_override\fP=""
|
||||||
If non\-empty, will use this string as identification instead of the actual hostname.
|
If non\-empty, will use this string as identification instead of the actual hostname.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-http\_check\_frequency\fP=20s
|
\fB\-\-http\_check\_frequency\fP=20s
|
||||||
Duration between checking http for new data.
|
Duration between checking http for new data.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_backtrace\_at\fP=:0
|
\fB\-\-log\_backtrace\_at\fP=:0
|
||||||
when logging hits line file:N, emit a stack trace.
|
when logging hits line file:N, emit a stack trace.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_dir\fP=""
|
\fB\-\-log\_dir\fP=""
|
||||||
If non\-empty, write log files in this directory.
|
If non\-empty, write log files in this directory.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-log\_flush\_frequency\fP=5s
|
\fB\-\-log\_flush\_frequency\fP=5s
|
||||||
Maximum number of seconds between log flushes.
|
Maximum number of seconds between log flushes.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-logtostderr\fP=false
|
\fB\-\-logtostderr\fP=false
|
||||||
log to standard error instead of files.
|
log to standard error instead of files.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-manifest\_url\fP=""
|
\fB\-\-manifest\_url\fP=""
|
||||||
URL for accessing the container manifest.
|
URL for accessing the container manifest.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-network\_container\_image\fP="kubernetes/pause:latest"
|
\fB\-\-network\_container\_image\fP="kubernetes/pause:latest"
|
||||||
The image that network containers in each pod will use.
|
The image that network containers in each pod will use.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-port\fP=10250
|
\fB\-\-port\fP=10250
|
||||||
The port for the info server to serve on.
|
The port for the info server to serve on.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-registry\_burst\fP=10
|
\fB\-\-registry\_burst\fP=10
|
||||||
Maximum size of a bursty pulls, temporarily allows pulls to burst to this number, while still not exceeding registry\_qps. Only used if \-\-registry\_qps > 0.
|
Maximum size of a bursty pulls, temporarily allows pulls to burst to this number, while still not exceeding registry\_qps. Only used if \-\-registry\_qps > 0.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-registry\_qps\fP=0
|
\fB\-\-registry\_qps\fP=0
|
||||||
If > 0, limit registry pull QPS to this value. If 0, unlimited. [default=0.0].
|
If > 0, limit registry pull QPS to this value. If 0, unlimited. [default=0.0].
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-root\_dir\fP="/var/lib/kubelet"
|
\fB\-\-root\_dir\fP="/var/lib/kubelet"
|
||||||
Directory path for managing kubelet files (volume mounts,etc).
|
Directory path for managing kubelet files (volume mounts,etc).
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-stderrthreshold\fP=0
|
\fB\-\-stderrthreshold\fP=0
|
||||||
logs at or above this threshold go to stderr.
|
logs at or above this threshold go to stderr.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-sync\_frequency\fP=10s
|
\fB\-\-sync\_frequency\fP=10s
|
||||||
Max period between synchronizing running containers and config.
|
Max period between synchronizing running containers and config.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-v\fP=0
|
\fB\-\-v\fP=0
|
||||||
log level for V logs.
|
log level for V logs.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-version\fP=false
|
\fB\-\-version\fP=false
|
||||||
Print version information and quit.
|
Print version information and quit.
|
||||||
|
|
||||||
.PP
|
.PP
|
||||||
\fB\-vmodule\fP=
|
\fB\-\-vmodule\fP=
|
||||||
comma\-separated list of pattern=N settings for file\-filtered logging.
|
comma\-separated list of pattern=N settings for file\-filtered logging.
|
||||||
|
|
||||||
.SH EXAMPLES
|
.SH EXAMPLES
|
||||||
|
@@ -82,4 +82,4 @@ else
|
|||||||
auth_config=()
|
auth_config=()
|
||||||
fi
|
fi
|
||||||
|
|
||||||
"${e2e}" "${auth_config[@]:+${auth_config[@]}}" -host="https://${KUBE_MASTER_IP-}"
|
"${e2e}" "${auth_config[@]:+${auth_config[@]}}" --host="https://${KUBE_MASTER_IP-}"
|
||||||
|
@@ -46,7 +46,7 @@ rm -rf ~/.kube*
|
|||||||
git clean -fdx
|
git clean -fdx
|
||||||
|
|
||||||
# Build
|
# Build
|
||||||
go run ./hack/e2e.go -v -build
|
go run ./hack/e2e.go -v --build
|
||||||
|
|
||||||
# Push to GCS
|
# Push to GCS
|
||||||
./build/push-ci-build.sh
|
./build/push-ci-build.sh
|
||||||
|
@@ -77,8 +77,8 @@ if [[ ! -z ${E2E_SET_CLUSTER_API_VERSION:-} ]]; then
|
|||||||
export CLUSTER_API_VERSION=$(echo ${GITHASH} | cut -c 2-)
|
export CLUSTER_API_VERSION=$(echo ${GITHASH} | cut -c 2-)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
go run ./hack/e2e.go ${E2E_OPT} -v -down
|
go run ./hack/e2e.go ${E2E_OPT} -v --down
|
||||||
go run ./hack/e2e.go ${E2E_OPT} -v -up
|
go run ./hack/e2e.go ${E2E_OPT} -v --up
|
||||||
go run ./hack/e2e.go -v -ctl="version --match-server-version=false"
|
go run ./hack/e2e.go -v --ctl="version --match-server-version=false"
|
||||||
go run ./hack/e2e.go ${E2E_OPT} --test -tap | tee ../e2e.${JOB_NAME}.${BUILD_NUMBER}.${GITHASH}.tap
|
go run ./hack/e2e.go ${E2E_OPT} --test --tap | tee ../e2e.${JOB_NAME}.${BUILD_NUMBER}.${GITHASH}.tap
|
||||||
go run ./hack/e2e.go ${E2E_OPT} -v -down
|
go run ./hack/e2e.go ${E2E_OPT} -v --down
|
||||||
|
@@ -89,7 +89,7 @@ GO_OUT="${KUBE_ROOT}/_output/local/bin/${host_os}/${host_arch}"
|
|||||||
|
|
||||||
APISERVER_LOG=/tmp/kube-apiserver.log
|
APISERVER_LOG=/tmp/kube-apiserver.log
|
||||||
sudo "${GO_OUT}/kube-apiserver" \
|
sudo "${GO_OUT}/kube-apiserver" \
|
||||||
-v=${LOG_LEVEL} \
|
--v=${LOG_LEVEL} \
|
||||||
--address="${API_HOST}" \
|
--address="${API_HOST}" \
|
||||||
--port="${API_PORT}" \
|
--port="${API_PORT}" \
|
||||||
--runtime_config=api/v1beta3 \
|
--runtime_config=api/v1beta3 \
|
||||||
@@ -103,14 +103,14 @@ kube::util::wait_for_url "http://${API_HOST}:${API_PORT}/api/v1beta1/pods" "apis
|
|||||||
|
|
||||||
CTLRMGR_LOG=/tmp/kube-controller-manager.log
|
CTLRMGR_LOG=/tmp/kube-controller-manager.log
|
||||||
sudo "${GO_OUT}/kube-controller-manager" \
|
sudo "${GO_OUT}/kube-controller-manager" \
|
||||||
-v=${LOG_LEVEL} \
|
--v=${LOG_LEVEL} \
|
||||||
--machines="127.0.0.1" \
|
--machines="127.0.0.1" \
|
||||||
--master="${API_HOST}:${API_PORT}" >"${CTLRMGR_LOG}" 2>&1 &
|
--master="${API_HOST}:${API_PORT}" >"${CTLRMGR_LOG}" 2>&1 &
|
||||||
CTLRMGR_PID=$!
|
CTLRMGR_PID=$!
|
||||||
|
|
||||||
KUBELET_LOG=/tmp/kubelet.log
|
KUBELET_LOG=/tmp/kubelet.log
|
||||||
sudo "${GO_OUT}/kubelet" \
|
sudo "${GO_OUT}/kubelet" \
|
||||||
-v=${LOG_LEVEL} \
|
--v=${LOG_LEVEL} \
|
||||||
--etcd_servers="http://127.0.0.1:4001" \
|
--etcd_servers="http://127.0.0.1:4001" \
|
||||||
--hostname_override="127.0.0.1" \
|
--hostname_override="127.0.0.1" \
|
||||||
--address="127.0.0.1" \
|
--address="127.0.0.1" \
|
||||||
@@ -121,13 +121,13 @@ KUBELET_PID=$!
|
|||||||
|
|
||||||
PROXY_LOG=/tmp/kube-proxy.log
|
PROXY_LOG=/tmp/kube-proxy.log
|
||||||
sudo "${GO_OUT}/kube-proxy" \
|
sudo "${GO_OUT}/kube-proxy" \
|
||||||
-v=${LOG_LEVEL} \
|
--v=${LOG_LEVEL} \
|
||||||
--master="http://${API_HOST}:${API_PORT}" >"${PROXY_LOG}" 2>&1 &
|
--master="http://${API_HOST}:${API_PORT}" >"${PROXY_LOG}" 2>&1 &
|
||||||
PROXY_PID=$!
|
PROXY_PID=$!
|
||||||
|
|
||||||
SCHEDULER_LOG=/tmp/kube-scheduler.log
|
SCHEDULER_LOG=/tmp/kube-scheduler.log
|
||||||
sudo "${GO_OUT}/kube-scheduler" \
|
sudo "${GO_OUT}/kube-scheduler" \
|
||||||
-v=${LOG_LEVEL} \
|
--v=${LOG_LEVEL} \
|
||||||
--master="http://${API_HOST}:${API_PORT}" >"${SCHEDULER_LOG}" 2>&1 &
|
--master="http://${API_HOST}:${API_PORT}" >"${SCHEDULER_LOG}" 2>&1 &
|
||||||
SCHEDULER_PID=$!
|
SCHEDULER_PID=$!
|
||||||
|
|
||||||
|
@@ -18,12 +18,12 @@ package resource
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"errors"
|
"errors"
|
||||||
"flag"
|
|
||||||
"fmt"
|
"fmt"
|
||||||
"math/big"
|
"math/big"
|
||||||
"regexp"
|
"regexp"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
|
flag "github.com/spf13/pflag"
|
||||||
"speter.net/go/exp/math/dec/inf"
|
"speter.net/go/exp/math/dec/inf"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -19,7 +19,6 @@ package api_test
|
|||||||
import (
|
import (
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
|
|
||||||
"flag"
|
|
||||||
"math/rand"
|
"math/rand"
|
||||||
"reflect"
|
"reflect"
|
||||||
"strconv"
|
"strconv"
|
||||||
@@ -37,6 +36,7 @@ import (
|
|||||||
|
|
||||||
docker "github.com/fsouza/go-dockerclient"
|
docker "github.com/fsouza/go-dockerclient"
|
||||||
fuzz "github.com/google/gofuzz"
|
fuzz "github.com/google/gofuzz"
|
||||||
|
flag "github.com/spf13/pflag"
|
||||||
"speter.net/go/exp/math/dec/inf"
|
"speter.net/go/exp/math/dec/inf"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@@ -18,7 +18,6 @@ package conversion
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"encoding/json"
|
"encoding/json"
|
||||||
"flag"
|
|
||||||
"fmt"
|
"fmt"
|
||||||
"reflect"
|
"reflect"
|
||||||
"strings"
|
"strings"
|
||||||
@@ -28,6 +27,7 @@ import (
|
|||||||
|
|
||||||
"github.com/ghodss/yaml"
|
"github.com/ghodss/yaml"
|
||||||
"github.com/google/gofuzz"
|
"github.com/google/gofuzz"
|
||||||
|
flag "github.com/spf13/pflag"
|
||||||
)
|
)
|
||||||
|
|
||||||
var fuzzIters = flag.Int("fuzz_iters", 50, "How many fuzzing iterations to do.")
|
var fuzzIters = flag.Int("fuzz_iters", 50, "How many fuzzing iterations to do.")
|
||||||
|
@@ -143,6 +143,10 @@ func (f *Factory) BindFlags(flags *pflag.FlagSet) {
|
|||||||
// any flags defined by external projects (not part of pflags)
|
// any flags defined by external projects (not part of pflags)
|
||||||
util.AddAllFlagsToPFlagSet(flags)
|
util.AddAllFlagsToPFlagSet(flags)
|
||||||
|
|
||||||
|
// This is necessary as github.com/spf13/cobra doesn't support "global"
|
||||||
|
// pflags currently. See https://github.com/spf13/cobra/issues/44.
|
||||||
|
util.AddPFlagSetToPFlagSet(pflag.CommandLine, flags)
|
||||||
|
|
||||||
if f.flags != nil {
|
if f.flags != nil {
|
||||||
f.flags.VisitAll(func(flag *pflag.Flag) {
|
f.flags.VisitAll(func(flag *pflag.Flag) {
|
||||||
flags.AddFlag(flag)
|
flags.AddFlag(flag)
|
||||||
|
27
pkg/util/flags.go
Normal file
27
pkg/util/flags.go
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
/*
|
||||||
|
Copyright 2014 Google Inc. All rights reserved.
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
||||||
|
*/
|
||||||
|
|
||||||
|
package util
|
||||||
|
|
||||||
|
import (
|
||||||
|
flag "github.com/spf13/pflag"
|
||||||
|
)
|
||||||
|
|
||||||
|
// InitFlags normalizes and parses the command line flags
|
||||||
|
func InitFlags() {
|
||||||
|
AddAllFlagsToPFlags()
|
||||||
|
flag.Parse()
|
||||||
|
}
|
@@ -22,9 +22,10 @@ import (
|
|||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/golang/glog"
|
"github.com/golang/glog"
|
||||||
|
"github.com/spf13/pflag"
|
||||||
)
|
)
|
||||||
|
|
||||||
var logFlushFreq = flag.Duration("log_flush_frequency", 5*time.Second, "Maximum number of seconds between log flushes")
|
var logFlushFreq = pflag.Duration("log_flush_frequency", 5*time.Second, "Maximum number of seconds between log flushes")
|
||||||
|
|
||||||
// TODO(thockin): This is temporary until we agree on log dirs and put those into each cmd.
|
// TODO(thockin): This is temporary until we agree on log dirs and put those into each cmd.
|
||||||
func init() {
|
func init() {
|
||||||
|
@@ -17,8 +17,9 @@ limitations under the License.
|
|||||||
package util
|
package util
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"flag"
|
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
|
flag "github.com/spf13/pflag"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestIP(t *testing.T) {
|
func TestIP(t *testing.T) {
|
||||||
|
@@ -42,7 +42,13 @@ func wrapFlagValue(v flag.Value) pflag.Value {
|
|||||||
pv := &flagValueWrapper{
|
pv := &flagValueWrapper{
|
||||||
inner: v,
|
inner: v,
|
||||||
}
|
}
|
||||||
pv.flagType = reflect.TypeOf(v).Elem().Name()
|
|
||||||
|
t := reflect.TypeOf(v)
|
||||||
|
if t.Kind() == reflect.Interface || t.Kind() == reflect.Ptr {
|
||||||
|
t = t.Elem()
|
||||||
|
}
|
||||||
|
|
||||||
|
pv.flagType = t.Name()
|
||||||
pv.flagType = strings.TrimSuffix(pv.flagType, "Value")
|
pv.flagType = strings.TrimSuffix(pv.flagType, "Value")
|
||||||
return pv
|
return pv
|
||||||
}
|
}
|
||||||
@@ -76,3 +82,17 @@ func AddFlagSetToPFlagSet(fsIn *flag.FlagSet, fsOut *pflag.FlagSet) {
|
|||||||
func AddAllFlagsToPFlagSet(fs *pflag.FlagSet) {
|
func AddAllFlagsToPFlagSet(fs *pflag.FlagSet) {
|
||||||
AddFlagSetToPFlagSet(flag.CommandLine, fs)
|
AddFlagSetToPFlagSet(flag.CommandLine, fs)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Add al of the top level 'flag' package flags to the top level 'pflag' flags.
|
||||||
|
func AddAllFlagsToPFlags() {
|
||||||
|
AddFlagSetToPFlagSet(flag.CommandLine, pflag.CommandLine)
|
||||||
|
}
|
||||||
|
|
||||||
|
// Merge all of the flags from fsFrom into fsTo.
|
||||||
|
func AddPFlagSetToPFlagSet(fsFrom *pflag.FlagSet, fsTo *pflag.FlagSet) {
|
||||||
|
fsFrom.VisitAll(func(f *pflag.Flag) {
|
||||||
|
if fsTo.Lookup(f.Name) == nil {
|
||||||
|
fsTo.AddFlag(f)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
@@ -19,12 +19,12 @@ limitations under the License.
|
|||||||
package verflag
|
package verflag
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"flag"
|
|
||||||
"fmt"
|
"fmt"
|
||||||
"os"
|
"os"
|
||||||
"strconv"
|
"strconv"
|
||||||
|
|
||||||
"github.com/GoogleCloudPlatform/kubernetes/pkg/version"
|
"github.com/GoogleCloudPlatform/kubernetes/pkg/version"
|
||||||
|
flag "github.com/spf13/pflag"
|
||||||
)
|
)
|
||||||
|
|
||||||
type versionValue int
|
type versionValue int
|
||||||
@@ -66,6 +66,11 @@ func (v *versionValue) String() string {
|
|||||||
return fmt.Sprintf("%v", bool(*v == VersionTrue))
|
return fmt.Sprintf("%v", bool(*v == VersionTrue))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// The type of the flag as requred by the pflag.Value interface
|
||||||
|
func (v *versionValue) Type() string {
|
||||||
|
return "version"
|
||||||
|
}
|
||||||
|
|
||||||
func VersionVar(p *versionValue, name string, value versionValue, usage string) {
|
func VersionVar(p *versionValue, name string, value versionValue, usage string) {
|
||||||
*p = value
|
*p = value
|
||||||
flag.Var(p, name, usage)
|
flag.Var(p, name, usage)
|
||||||
|
@@ -17,7 +17,6 @@ limitations under the License.
|
|||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"flag"
|
|
||||||
"net"
|
"net"
|
||||||
"net/http"
|
"net/http"
|
||||||
"strconv"
|
"strconv"
|
||||||
@@ -33,6 +32,8 @@ import (
|
|||||||
_ "github.com/GoogleCloudPlatform/kubernetes/plugin/pkg/scheduler/algorithmprovider"
|
_ "github.com/GoogleCloudPlatform/kubernetes/plugin/pkg/scheduler/algorithmprovider"
|
||||||
"github.com/GoogleCloudPlatform/kubernetes/plugin/pkg/scheduler/factory"
|
"github.com/GoogleCloudPlatform/kubernetes/plugin/pkg/scheduler/factory"
|
||||||
"github.com/golang/glog"
|
"github.com/golang/glog"
|
||||||
|
|
||||||
|
flag "github.com/spf13/pflag"
|
||||||
)
|
)
|
||||||
|
|
||||||
var (
|
var (
|
||||||
@@ -47,7 +48,7 @@ func init() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
flag.Parse()
|
util.InitFlags()
|
||||||
util.InitLogs()
|
util.InitLogs()
|
||||||
defer util.FlushLogs()
|
defer util.FlushLogs()
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user