mirror of https://github.com/easzlab/kubeasz.git
fix集群清理相关
parent
49993180fb
commit
b3daae9c97
|
@ -72,7 +72,7 @@
|
|||
&& iptables -F -t mangle && iptables -X -t mangle"
|
||||
|
||||
- name: 清理网络
|
||||
shell: "ip link del docker0; ip link del tunl0; systemctl restart networking"
|
||||
shell: "ip link del docker0; ip link del tunl0; systemctl restart networking; systemctl restart network"
|
||||
ignore_errors: true
|
||||
|
||||
- hosts: etcd
|
||||
|
|
|
@ -14,7 +14,7 @@ metadata:
|
|||
name: kube-dns
|
||||
namespace: kube-system
|
||||
labels:
|
||||
kubernetes.io/cluster-service: "true"
|
||||
#kubernetes.io/cluster-service: "true"
|
||||
addonmanager.kubernetes.io/mode: Reconcile
|
||||
|
||||
---
|
||||
|
@ -25,7 +25,7 @@ metadata:
|
|||
namespace: kube-system
|
||||
labels:
|
||||
k8s-app: kube-dns
|
||||
kubernetes.io/cluster-service: "true"
|
||||
#kubernetes.io/cluster-service: "true"
|
||||
addonmanager.kubernetes.io/mode: Reconcile
|
||||
kubernetes.io/name: "KubeDNS"
|
||||
spec:
|
||||
|
@ -48,7 +48,7 @@ metadata:
|
|||
namespace: kube-system
|
||||
labels:
|
||||
k8s-app: kube-dns
|
||||
kubernetes.io/cluster-service: "true"
|
||||
#kubernetes.io/cluster-service: "true"
|
||||
addonmanager.kubernetes.io/mode: Reconcile
|
||||
spec:
|
||||
# replicas: not specified here:
|
||||
|
|
|
@ -32,6 +32,26 @@
|
|||
- name: 缓存ansilbe setup信息
|
||||
setup: gather_subset=min
|
||||
|
||||
# 删除默认安装
|
||||
- name: 删除ubuntu默认安装
|
||||
when: ansible_distribution == "Ubuntu"
|
||||
apt: name={{ item }} state=absent
|
||||
with_items:
|
||||
- ufw
|
||||
- lxd
|
||||
- lxd-client
|
||||
- lxcfs
|
||||
- lxc-common
|
||||
|
||||
# 删除默认安装
|
||||
- name: 删除centos默认安装
|
||||
when: ansible_distribution == "CentOS"
|
||||
yum: name={{ item }} state=absent
|
||||
with_items:
|
||||
- firewalld
|
||||
- firewalld-filesystem
|
||||
- python-firewall
|
||||
|
||||
- name: 关闭 selinux
|
||||
shell: "setenforce 0 && echo SELINUX=disabled > /etc/selinux/config"
|
||||
when: ansible_distribution == "CentOS"
|
||||
|
|
Loading…
Reference in New Issue