mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-25 12:43:23 +00:00
Further vagrant reliability improvements.
This commit is contained in:
parent
b583d4edb4
commit
35ab4ccc6d
@ -5,6 +5,7 @@ Documentation=https://github.com/GoogleCloudPlatform/kubernetes
|
|||||||
[Service]
|
[Service]
|
||||||
EnvironmentFile=/etc/sysconfig/kube-apiserver
|
EnvironmentFile=/etc/sysconfig/kube-apiserver
|
||||||
ExecStart=/usr/local/bin/kube-apiserver "$DAEMON_ARGS"
|
ExecStart=/usr/local/bin/kube-apiserver "$DAEMON_ARGS"
|
||||||
|
Restart=on-failure
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
|
@ -3,9 +3,9 @@ Description=Kubernetes Controller Manager
|
|||||||
Documentation=https://github.com/GoogleCloudPlatform/kubernetes
|
Documentation=https://github.com/GoogleCloudPlatform/kubernetes
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
Type=simple
|
|
||||||
EnvironmentFile=-/etc/sysconfig/kube-controller-manager
|
EnvironmentFile=-/etc/sysconfig/kube-controller-manager
|
||||||
ExecStart=/usr/local/bin/kube-controller-manager "$DAEMON_ARGS"
|
ExecStart=/usr/local/bin/kube-controller-manager "$DAEMON_ARGS"
|
||||||
|
Restart=on-failure
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
|
@ -5,6 +5,7 @@ Documentation=https://github.com/GoogleCloudPlatform/kubernetes
|
|||||||
[Service]
|
[Service]
|
||||||
EnvironmentFile=/etc/sysconfig/kube-proxy
|
EnvironmentFile=/etc/sysconfig/kube-proxy
|
||||||
ExecStart=/usr/local/bin/kube-proxy "$DAEMON_ARGS"
|
ExecStart=/usr/local/bin/kube-proxy "$DAEMON_ARGS"
|
||||||
|
Restart=on-failure
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
|
@ -6,6 +6,7 @@ Documentation=https://github.com/GoogleCloudPlatform/kubernetes
|
|||||||
Type=simple
|
Type=simple
|
||||||
EnvironmentFile=-/etc/sysconfig/kube-scheduler
|
EnvironmentFile=-/etc/sysconfig/kube-scheduler
|
||||||
ExecStart=/usr/local/bin/kube-scheduler "$DAEMON_ARGS"
|
ExecStart=/usr/local/bin/kube-scheduler "$DAEMON_ARGS"
|
||||||
|
Restart=on-failure
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
||||||
|
@ -1,10 +1,13 @@
|
|||||||
[Unit]
|
[Unit]
|
||||||
Description=Kubernetes Kubelet Server
|
Description=Kubernetes Kubelet Server
|
||||||
Documentation=https://github.com/GoogleCloudPlatform/kubernetes
|
Documentation=https://github.com/GoogleCloudPlatform/kubernetes
|
||||||
|
After=docker.service
|
||||||
|
Requires=docker.service
|
||||||
|
|
||||||
[Service]
|
[Service]
|
||||||
EnvironmentFile=/etc/sysconfig/kubelet
|
EnvironmentFile=/etc/sysconfig/kubelet
|
||||||
ExecStart=/usr/local/bin/kubelet "$DAEMON_ARGS"
|
ExecStart=/usr/local/bin/kubelet "$DAEMON_ARGS"
|
||||||
|
Restart=on-failure
|
||||||
|
|
||||||
[Install]
|
[Install]
|
||||||
WantedBy=multi-user.target
|
WantedBy=multi-user.target
|
@ -1,8 +1,13 @@
|
|||||||
{% if grains.network_mode is defined and grains.network_mode == 'openvswitch' %}
|
{% if grains.network_mode is defined and grains.network_mode == 'openvswitch' %}
|
||||||
|
|
||||||
|
|
||||||
sdn:
|
sdn:
|
||||||
cmd.wait:
|
cmd.script:
|
||||||
- name: /kubernetes-vagrant/network_closure.sh
|
- source: /kubernetes-vagrant/network_closure.sh
|
||||||
- watch:
|
- require:
|
||||||
- sls: docker
|
- pkg: docker-io
|
||||||
|
- cwd: /
|
||||||
|
- user: root
|
||||||
|
- group: root
|
||||||
|
- shell: /bin/bash
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
@ -31,8 +31,8 @@ cat <<EOF > ${POST_NETWORK_SCRIPT}
|
|||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
# Only do this operation once, otherwise, we get docker.service files output on disk, and the command line arguments get applied multiple times
|
# Only do this operation if the bridge is not defined
|
||||||
grep -q kbr0 /etc/sysconfig/docker || {
|
ifconfig | grep -q kbr0 || {
|
||||||
CONTAINER_SUBNETS=(${MASTER_CONTAINER_SUBNET} ${MINION_CONTAINER_SUBNETS[@]})
|
CONTAINER_SUBNETS=(${MASTER_CONTAINER_SUBNET} ${MINION_CONTAINER_SUBNETS[@]})
|
||||||
CONTAINER_IPS=(${MASTER_IP} ${MINION_IPS[@]})
|
CONTAINER_IPS=(${MASTER_IP} ${MINION_IPS[@]})
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user