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

Commit

Permalink
Merge pull request #137 from goodrain/v3.7-patch09
Browse files Browse the repository at this point in the history
V3.7 patch09
ysicing authored Aug 23, 2018
2 parents 6cd35b7 + da43aa2 commit c68c892
Showing 5 changed files with 22 additions and 19 deletions.
4 changes: 2 additions & 2 deletions install/salt/common/init.sls
Original file line number Diff line number Diff line change
@@ -3,7 +3,7 @@ include:
- common.key
- common.user
- common.limits
- common.swap
# - common.swap
- common.create_dir
- common.service
- common.plugins
@@ -18,7 +18,7 @@ include:
{% else %}
- common.user
- common.create_dir
- common.swap
# - common.swap
- common.limits
- common.service
- common.key
15 changes: 11 additions & 4 deletions install/salt/common/service.sls
Original file line number Diff line number Diff line change
@@ -28,10 +28,17 @@ remove_pkgs:
# - cmd: kill-dhclient

{% if grains['os_family']|lower == 'debian' %}
NetworkManager:
service.dead:
- name: NetworkManager
- enable: False
#NetworkManager:
# service.dead:
# - name: NetworkManager
# - enable: False
NetworkManager-conf:
file.managed:
- source: salt://install/files/network/system/calico.conf
- name: /etc/NetworkManager/conf.d/calico.conf
- template: jinja
- mode: 755
- makedirs: True
{% endif %}

iptables:
7 changes: 1 addition & 6 deletions install/salt/docker/install.sls
Original file line number Diff line number Diff line change
@@ -32,12 +32,7 @@ docker-repo:
pkgrepo.managed:
{% if grains['os_family']|lower == 'redhat' %}
{% if pillar['install-type']=="offline" %}
{% if grains['id']=="manage01" %}
- humanname: local_repo
- baseurl: file://{{ pillar['install-script-path' ]}}/install/pkgs/centos/
- enabled: 1
- gpgcheck: 0
{% else %}
{% if grains['id']!= "manage01" %}
- humanname: local_repo
- baseurl: http://repo.goodrain.me/
- enabled: 1
2 changes: 2 additions & 0 deletions install/salt/install/files/network/system/calico.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[keyfile]
unmanaged-devices=interface-name:cali*;interface-name:tunl*
13 changes: 6 additions & 7 deletions setup.sh
Original file line number Diff line number Diff line change
@@ -117,18 +117,16 @@ END
else
mkdir -p /etc/yum.repos.d/backup >/dev/null 2>&1
mv -f /etc/yum.repos.d/*.repo /etc/yum.repos.d/backup >/dev/null 2>&1
cat > /etc/yum.repos.d/rainbond_local.repo << EOF
[rainbond_local]
cat > /etc/yum.repos.d/rbd-local.repo << EOF
[rbd-local]
name=rainbond_offline_install_repo
baseurl=file:///opt/rainbond/install/install/pkgs/centos/
gpgcheck=0
enabled=1
EOF
rpm -ivh /opt/rainbond/install/install/pkgs/centos/deltarpm-*.rpm 1>/dev/null
rpm -ivh /opt/rainbond/install/install/pkgs/centos/libxml2-python-*.rpm 1>/dev/null
rpm -ivh /opt/rainbond/install/install/pkgs/centos/python-deltarpm-*.rpm 1>/dev/null
rpm -ivh /opt/rainbond/install/install/pkgs/centos/createrepo-*.rpm 1>/dev/null

yum makecache fast >/dev/null 2>&1
yum install createrepo -y 1>/dev/null
createrepo /opt/rainbond/install/install/pkgs/centos/ 1>/dev/null
fi

@@ -147,6 +145,7 @@ else
cat > /etc/apt/sources.list.d/salt.list << END
deb https://mirrors.ustc.edu.cn/salt/apt/debian/9/amd64/2018.3 stretch main
END

fi

#=================== base show func ==========================================
@@ -755,7 +754,7 @@ install_func(){
Echo_Error "Please check node status[uuid], Just Run systemctl status node"
exit 1
fi
for ((i=1;i<=30;i++ ));do
for ((i=1;i<=60;i++ ));do
sleep 1
notready=$(grctl node list | grep $uuid | grep offline)
[ ! -z "$notready" ] && (

0 comments on commit c68c892

Please sign in to comment.