Skip to content

Commit

Permalink
Update k8s to 1.14.2
Browse files Browse the repository at this point in the history
  • Loading branch information
marcosnils committed May 22, 2019
1 parent b758b00 commit a35c99b
Show file tree
Hide file tree
Showing 4 changed files with 35 additions and 4 deletions.
5 changes: 3 additions & 2 deletions dockerfiles/k8s/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ COPY ./kubernetes.repo /etc/yum.repos.d/



RUN yum install -y kubectl-1.11.3-0 kubeadm-1.11.3-0 kubelet-1.11.3-0 \
&& mv -f /etc/systemd/system/kubelet.service.d/10-kubeadm.conf /etc/systemd/system/kubelet.service \
RUN yum install -y kubectl-1.14.2 kubeadm-1.14.2 kubelet-1.14.2 \
#&& mv -f /etc/systemd/system/kubelet.service.d/10-kubeadm.conf /etc/systemd/system/kubelet.service \
&& yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo \
&& yum install -y docker-ce git \
&& sed -i -e '4d;5d;8d' /lib/systemd/system/docker.service \
Expand All @@ -24,6 +24,7 @@ COPY ./wrapkubeadm.sh /usr/local/bin/kubeadm
COPY ./tokens.csv /etc/pki/tokens.csv
COPY ./daemon.json /etc/docker/
COPY ./resolv.conf.override /etc/
COPY ./docker.service /usr/lib/systemd/system/

COPY motd /etc/motd

Expand Down
30 changes: 30 additions & 0 deletions dockerfiles/k8s/docker.service
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
[Unit]
Description=Docker Application Container Engine
Documentation=https://docs.docker.com

[Service]
# the default is not to use systemd for cgroups because the delegate issues still
# exists and systemd currently does not support the cgroup feature set required
# for containers run by docker
ExecStart=/usr/bin/dockerd
ExecReload=/bin/kill -s HUP $MAINPID
# Having non-zero Limit*s causes performance problems due to accounting overhead
# in the kernel. We recommend using cgroups to do container-local accounting.
LimitNOFILE=infinity
LimitNPROC=infinity
LimitCORE=infinity
# Uncomment TasksMax if your systemd version supports it.
# Only systemd 226 and above support this version.
#TasksMax=infinity
TimeoutStartSec=0
# set delegate yes so that systemd does not reset the cgroups of docker containers
Delegate=yes
# kill only the docker process, not all processes in the cgroup
KillMode=process
# restart the docker process if it exits prematurely
Restart=on-failure
StartLimitBurst=3
StartLimitInterval=60s

[Install]
WantedBy=multi-user.target
2 changes: 1 addition & 1 deletion dockerfiles/k8s/kubelet.env
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ KUBELET_NETWORK_ARGS="--network-plugin=cni --cni-conf-dir=/etc/cni/net.d --cni-b
KUBELET_DNS_ARGS="--cluster-dns=10.96.0.10 --cluster-domain=cluster.local"
KUBELET_AUTHZ_ARGS="--authorization-mode=Webhook --client-ca-file=/etc/kubernetes/pki/ca.crt"
KUBELET_CGROUP_ARGS="--cgroup-driver=cgroupfs"
KUBELET_EXTRA_ARGS="--fail-swap-on=false --resolv-conf=/etc/resolv.conf.override"
KUBELET_EXTRA_ARGS="--fail-swap-on=false --resolv-conf=/etc/resolv.conf.override --feature-gates ExperimentalCriticalPodAnnotation=true"
2 changes: 1 addition & 1 deletion dockerfiles/k8s/wrapkubeadm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ function dind::wait-for-apiserver {
}

function dind::frob-cluster {
dind::frob-apiserver
#dind::frob-apiserver
dind::wait-for-apiserver
dind::frob-proxy
}
Expand Down

0 comments on commit a35c99b

Please sign in to comment.