Fix a bunch of places where the -machines flag was still attached to the apiserver.

This commit is contained in:
Brendan Burns 2014-11-01 20:38:45 -07:00
parent bbb66af3db
commit 8d34231381
17 changed files with 36 additions and 27 deletions

View File

@ -14,8 +14,4 @@
# See the License for the specific language governing permissions and
# limitations under the License.
# If the user doesn't specify a minion, assume we are running in a single node
# configuration and that we have a local minion.
KUBE_MINIONS="${KUBE_MINIONS:-$(hostname -f)}"
./apiserver -address=0.0.0.0 -etcd_servers="${ETCD_SERVERS}" --machines="${KUBE_MINIONS}"
./apiserver -address=0.0.0.0 -etcd_servers="${ETCD_SERVERS}"

View File

@ -39,11 +39,11 @@ containers:
hostPort: 8080
containerPort: 8080
protocol: TCP
command: ["/kubernetes/apiserver", "-v=5", "-address=0.0.0.0", "-etcd_servers=http://127.0.0.1:4001", "-machines=${KUBELET_IP}"]
command: ["/kubernetes/apiserver", "-v=5", "-address=0.0.0.0", "-etcd_servers=http://127.0.0.1:4001"]
- name: controller-manager
image: kubernetes
imagePullPolicy: never
command: ["/kubernetes/controller-manager", "-v=5", "-master=127.0.0.1:8080"]
command: ["/kubernetes/controller-manager", "-v=5", "-master=127.0.0.1:8080", "-machines=${KUBELET_IP}"]
- name: proxy
image: kubernetes
imagePullPolicy: never

View File

@ -14,4 +14,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.
./controller-manager -master="${API_SERVER}"
# If the user doesn't specify a minion, assume we are running in a single node
# configuration and that we have a local minion.
KUBE_MINIONS="${KUBE_MINIONS:-$(hostname -f)}"
./controller-manager -master="${API_SERVER}" --machines="${KUBE_MINIONS}"

View File

@ -77,7 +77,7 @@ coreos:
[Service]
EnvironmentFile=-/run/apiserver/minions.env
ExecStartPre=/usr/bin/ln -sf /opt/kubernetes/server/bin/apiserver /opt/bin/apiserver
ExecStart=/opt/bin/apiserver --address=127.0.0.1 --port=8080 --machines=${MINIONS} --etcd_servers=http://127.0.0.1:4001 --portal_net=PORTAL_NET --logtostderr=true
ExecStart=/opt/bin/apiserver --address=127.0.0.1 --port=8080 --etcd_servers=http://127.0.0.1:4001 --portal_net=PORTAL_NET --logtostderr=true
Restart=always
RestartSec=2
- name: master-apiserver-sighup.path
@ -116,7 +116,7 @@ coreos:
Requires=master-apiserver.service
[Service]
ExecStartPre=/usr/bin/ln -sf /opt/kubernetes/server/bin/controller-manager /opt/bin/controller-manager
ExecStart=/opt/bin/controller-manager --master=127.0.0.1:8080 --logtostderr=true
ExecStart=/opt/bin/controller-manager --master=127.0.0.1:8080 --machines=${MINIONS} --logtostderr=true
Restart=always
RestartSec=2
- name: master-scheduler.service

View File

@ -13,9 +13,6 @@ KUBE_API_PORT="--port=8080"
# How the replication controller and scheduler find the apiserver
KUBE_MASTER="--master=127.0.0.1:8080"
# Comma seperated list of minions
KUBELET_ADDRESSES="--machines=127.0.0.1"
# Port minions listen on
KUBELET_PORT="--kubelet_port=10250"

View File

@ -3,5 +3,8 @@
# defaults from config and apiserver should be adequate
# Comma seperated list of minions
KUBELET_ADDRESSES="--machines=127.0.0.1"
# Add you own!
KUBE_CONTROLLER_MANAGER_ARGS=""

View File

@ -12,7 +12,6 @@ ExecStart=/usr/bin/kube-apiserver \
${KUBE_ETCD_SERVERS} \
${KUBE_API_ADDRESS} \
${KUBE_API_PORT} \
${KUBELET_ADDRESSES} \
${KUBELET_PORT} \
${KUBE_ALLOW_PRIV} \
${KUBE_SERVICE_ADDRESSES} \

View File

@ -10,6 +10,7 @@ User=kube
ExecStart=/usr/bin/kube-controller-manager \
${KUBE_LOGTOSTDERR} \
${KUBE_LOG_LEVEL} \
${KUBELET_ADDRESSES} \
${KUBE_MASTER} \
${KUBE_CONTROLLER_MANAGER_ARGS}
Restart=on-failure

View File

@ -119,7 +119,6 @@ coreos:
--address=127.0.0.1 \
--port=8080 \
--etcd_servers=http://127.0.0.1:4001 \
--machines=192.168.12.10,192.168.12.11,192.168.12.12 \
--logtostderr=true
Restart=always
RestartSec=10
@ -161,6 +160,7 @@ coreos:
[Service]
ExecStart=/opt/bin/controller-manager \
--master=127.0.0.1:8080 \
--machines=192.168.12.10,192.168.12.11,192.168.12.12 \
--logtostderr=true
Restart=always
RestartSec=10

View File

@ -48,7 +48,6 @@ coreos:
--address=127.0.0.1 \
--port=8080 \
--etcd_servers=http://127.0.0.1:4001 \
--machines=127.0.0.1 \
--logtostderr=true
Restart=on-failure
RestartSec=1
@ -86,6 +85,7 @@ coreos:
[Service]
ExecStart=/opt/bin/controller-manager \
--master=127.0.0.1:8080 \
--machines=127.0.0.1 \
--logtostderr=true
Restart=on-failure
RestartSec=1

View File

@ -8,7 +8,6 @@ ExecStart=/opt/bin/apiserver \
--address=127.0.0.1 \
--port=8080 \
--etcd_servers=http://127.0.0.1:4001 \
--machines=127.0.0.1 \
--portal_net=10.0.0.0/24 \
--logtostderr=true
Restart=on-failure

View File

@ -6,6 +6,7 @@ Documentation=https://github.com/GoogleCloudPlatform/kubernetes
[Service]
ExecStart=/opt/bin/controller-manager \
--master=127.0.0.1:8080 \
--machines=127.0.0.1 \
--etcd_servers=http://127.0.0.1:4001 \
--logtostderr=true
Restart=on-failure

View File

@ -102,9 +102,6 @@ KUBE_API_PORT="--port=8080"
# How the replication controller and scheduler find the apiserver
KUBE_MASTER="--master=fed-master:8080"
# Comma seperated list of minions
KUBELET_ADDRESSES="--machines=fed-minion"
# Port minions listen on
KUBELET_PORT="--kubelet_port=10250"
@ -115,6 +112,18 @@ KUBE_SERVICE_ADDRESSES="--portal_net=10.254.0.0/16"
KUBE_API_ARGS=""
```
* Edit /etc/kubernetes/controller-manager to appear as such:
```
###
# kubernetes system config
#
# The following values are used to configure the kubernetes-controller-manager
#
# Comma seperated list of minions
KUBELET_ADDRESSES="--machines=fed-minion"
```
* Start the appropriate services on master:
```

View File

@ -53,9 +53,6 @@ The the kube-apiserver several options.
**-logtostderr**=
log to standard error instead of files. Default is false.
**-machines**=[]
List of machines to schedule onto, comma separated.
**-minion_cache_ttl**=30s
Duration of time to cache minion information. Default 30 seconds.

View File

@ -44,6 +44,9 @@ The kube-controller-manager has several options.
**-logtostderr**=false
log to standard error instead of files.
**-machines**=[]
List of machines to schedule onto, comma separated.
**-master**=""
The address of the Kubernetes API server.

View File

@ -69,10 +69,6 @@ The the kube\-apiserver several options.
\fB\-logtostderr\fP=
log to standard error instead of files. Default is false.
.PP
\fB\-machines\fP=[]
List of machines to schedule onto, comma separated.
.PP
\fB\-minion\_cache\_ttl\fP=30s
Duration of time to cache minion information. Default 30 seconds.

View File

@ -56,6 +56,10 @@ The kube\-controller\-manager has several options.
\fB\-logtostderr\fP=false
log to standard error instead of files.
.PP
\fB\-machines\fP=[]
List of machines to schedule onto, comma separated.
.PP
\fB\-master\fP=""
The address of the Kubernetes API server.