Skip to content
This repository has been archived by the owner on Jul 14, 2019. It is now read-only.

Commit

Permalink
Merge branch 'master' into lowercase2
Browse files Browse the repository at this point in the history
  • Loading branch information
davidewatson committed Dec 7, 2018
2 parents 09bf5b0 + f020d7c commit 138d9eb
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .versionfile
@@ -1 +1 @@
0.1.42
0.1.43
Expand Up @@ -6,7 +6,9 @@

dockerRpms=$(rpm -qa 'docker*')
if [[ -z "${dockerRpms// }" ]];then
if ! yum install docker -y;then
# https://github.com/openshift/origin/issues/21609
# https://bugzilla.redhat.com/show_bug.cgi?id=1655975
if ! yum install docker-1.13.1-75.git8633870.el7.centos -y;then
echo >&2 "Unable to install docker"
return 1
fi
Expand Down Expand Up @@ -215,8 +217,9 @@
return 1
fi

echo -e '\n127.0.0.1 registry-1.docker.io gcr.io k8s.gcr.io quay.io\n' >> /etc/hosts
echo -e '\n182.193.17.192 sds.redii.net\n' >> /etc/hosts
echo "$(ifconfig ens192 | grep -Po 'inet (\d{1,3}\.?)+' | awk '{print $2}') $(hostname)" >> /etc/hosts
echo "127.0.0.1 registry-1.docker.io gcr.io k8s.gcr.io quay.io" >> /etc/hosts
echo -e "182.193.17.192 sds.redii.net\n" >> /etc/hosts
}

install_k8s_w_yum()
Expand Down Expand Up @@ -289,17 +292,27 @@
fi

yum install -y conntrack
modprobe br_netfilter

if ! swapoff -a;then
echo >&2 "Unable to turn off swapping"
return 1
fi

# make sure swap is off after reboots
if grep -Pq '^/dev/mapper/centos-swap' /etc/fstab; then
sed -ri.bak-$(date +%Y%m%dT%H%M%S) 's/(.*centos-swap.*)/#\1/' /etc/fstab
fi

cat <<EOF > /etc/sysctl.d/k8s.conf
net.bridge.bridge-nf-call-ip6tables = 1
net.bridge.bridge-nf-call-iptables = 1
EOF

# stop and disable firewall
systemctl stop firewalld
systemctl disable firewalld

if ! sysctl --system;then
echo >&2 "Unable to set net.bridge.bridge-nf-call-iptables sysctl settings"
return 1
Expand Down

0 comments on commit 138d9eb

Please sign in to comment.