Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
k3s
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Jacklull
k3s
Commits
87bf85a6
Commit
87bf85a6
authored
Dec 10, 2015
by
k8s-merge-robot
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #18489 from ZJU-SEL/config-apiserver-advertise-addr
Auto commit by PR queue bot
parents
940f5d44
c46957ed
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
11 deletions
+17
-11
apiserver.sh
cluster/centos/master/scripts/apiserver.sh
+10
-5
util.sh
cluster/ubuntu/util.sh
+7
-6
No files found.
cluster/centos/master/scripts/apiserver.sh
View file @
87bf85a6
...
...
@@ -31,15 +31,19 @@ KUBE_LOG_LEVEL="--v=4"
# comma separated. Mutually exclusive with -etcd-config
KUBE_ETCD_SERVERS="--etcd-servers=
${
ETCD_SERVERS
}
"
# --
address=127.0.0.1: DEPRECATED: see --insecure-bind-address instead
KUBE_API_ADDRESS="--address=
${
MASTER_ADDRESS
}
"
# --
insecure-bind-address=127.0.0.1: The IP address on which to serve the --insecure-port.
KUBE_API_ADDRESS="--
insecure-bind-
address=
${
MASTER_ADDRESS
}
"
# --
port=8080: DEPRECATED: see --insecure-port instead
KUBE_API_PORT="--port=8080"
# --
insecure-port=8080: The port on which to serve unsecured, unauthenticated access.
KUBE_API_PORT="--
insecure-
port=8080"
# --kubelet-port=10250: Kubelet port
NODE_PORT="--kubelet-port=10250"
# --advertise-address=<nil>: The IP address on which to advertise
# the apiserver to members of the cluster.
KUBE_ADVERTISE_ADDR="--advertise-address=
${
MASTER_ADDRESS
}
"
# --allow-privileged=false: If true, allow privileged containers.
KUBE_ALLOW_PRIV="--allow-privileged=false"
...
...
@@ -75,7 +79,8 @@ KUBE_APISERVER_OPTS=" \${KUBE_LOGTOSTDERR} \\
\$
{KUBE_ETCD_SERVERS}
\\
\$
{KUBE_API_ADDRESS}
\\
\$
{KUBE_API_PORT}
\\
\$
{NODE_PORT}
\\
\$
{NODE_PORT}
\\
\$
{KUBE_ADVERTISE_ADDR}
\\
\$
{KUBE_ALLOW_PRIV}
\\
\$
{KUBE_SERVICE_ADDRESSES}
\\
\$
{KUBE_ADMISSION_CONTROL}
\\
...
...
cluster/ubuntu/util.sh
View file @
87bf85a6
...
...
@@ -203,6 +203,7 @@ KUBE_APISERVER_OPTS="\
--service-cluster-ip-range=
${
1
}
\
--admission-control=
${
2
}
\
--service-node-port-range=
${
3
}
\
--advertise-address=
${
4
}
\
--client-ca-file=/srv/kubernetes/ca.crt\
--tls-cert-file=/srv/kubernetes/server.cert\
--tls-private-key-file=/srv/kubernetes/server.key"
...
...
@@ -232,14 +233,12 @@ EOF
function
create-kubelet-opts
()
{
cat
<<
EOF
> ~/kube/default/kubelet
KUBELET_OPTS="\
--address=0.0.0.0\
--port=10250 \
--hostname-override=
${
1
}
\
--api-servers=http://
${
2
}
:8080 \
--logtostderr=true \
--config=/etc/kubernetes/manifests \
--cluster-dns=
$
3
\
--cluster-domain=
$
4
"
--cluster-dns=
$
{
3
}
\
--cluster-domain=
$
{
4
}
"
EOF
}
...
...
@@ -383,7 +382,8 @@ function provision-master() {
create-kube-apiserver-opts
\
'
${
SERVICE_CLUSTER_IP_RANGE
}
'
\
'
${
ADMISSION_CONTROL
}
'
\
'
${
SERVICE_NODE_PORT_RANGE
}
'
'
${
SERVICE_NODE_PORT_RANGE
}
'
\
'
${
MASTER_IP
}
'
create-kube-controller-manager-opts '
${
NODE_IPS
}
'
create-kube-scheduler-opts
create-flanneld-opts '127.0.0.1' '
${
MASTER_IP
}
'
...
...
@@ -487,7 +487,8 @@ function provision-masterandnode() {
create-kube-apiserver-opts
\
'
${
SERVICE_CLUSTER_IP_RANGE
}
'
\
'
${
ADMISSION_CONTROL
}
'
\
'
${
SERVICE_NODE_PORT_RANGE
}
'
'
${
SERVICE_NODE_PORT_RANGE
}
'
\
'
${
MASTER_IP
}
'
create-kube-controller-manager-opts '
${
NODE_IPS
}
'
create-kube-scheduler-opts
create-kubelet-opts
\
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment