调整:docker/containerd运行时安装互不影响

pull/1076/head 3.1.1
gjmzj 2021-09-25 11:41:34 +08:00
parent ad7f1082f7
commit 8d24ad9b03
4 changed files with 4 additions and 15 deletions

View File

@ -32,4 +32,4 @@ kubeasz 用户可以确认集群各项功能符合预期既符合k8s设计标
- 修复coredns 1.8.4 rbac settings - 修复coredns 1.8.4 rbac settings
- 修复docker/containerd是否需要安装的判断条件 - 修复docker/containerd是否需要安装的判断条件
- 修复暂时绕过centos7.9开启KUBE_RESERVED的问题 - 修复暂时绕过centos7.9开启KUBE_RESERVED的问题
- 调整docker/containerd运行时安装互不影响

View File

@ -25,6 +25,8 @@
- name: prepare some dirs - name: prepare some dirs
file: name={{ cluster_dir }}/yml/dashboard state=directory file: name={{ cluster_dir }}/yml/dashboard state=directory
run_once: true
connection: local
- name: 准备 dashboard的部署文件 - name: 准备 dashboard的部署文件
template: src=dashboard/{{ item }}.j2 dest={{ cluster_dir }}/yml/dashboard/{{ item }} template: src=dashboard/{{ item }}.j2 dest={{ cluster_dir }}/yml/dashboard/{{ item }}

View File

@ -1,12 +1,3 @@
- name: 获取是否已经安装docker
shell: 'systemctl is-active docker || echo "NoFound"'
register: docker_status
- name: WARNNING 提示
debug:
msg: "[WARN]: docker is running, and containerd will be installed"
when: '"NoFound" not in docker_status.stdout'
- name: 获取是否已经安装containerd - name: 获取是否已经安装containerd
shell: 'systemctl is-active containerd || echo "NoFound"' shell: 'systemctl is-active containerd || echo "NoFound"'
register: containerd_svc register: containerd_svc

View File

@ -2,10 +2,6 @@
shell: 'systemctl is-active docker || echo "NoFound"' shell: 'systemctl is-active docker || echo "NoFound"'
register: docker_svc register: docker_svc
- name: 获取是否已经安装containerd
shell: 'systemctl is-active containerd || echo "NoFound"'
register: containerd_svc
# 18.09.x 版本二进制名字有变化,需要做判断 # 18.09.x 版本二进制名字有变化,需要做判断
- name: 获取docker版本信息 - name: 获取docker版本信息
shell: "{{ base_dir }}/bin/dockerd --version|cut -d' ' -f3" shell: "{{ base_dir }}/bin/dockerd --version|cut -d' ' -f3"
@ -113,7 +109,7 @@
- name: 配置 docker 命令软链接 - name: 配置 docker 命令软链接
file: src={{ bin_dir }}/docker dest=/usr/bin/docker state=link file: src={{ bin_dir }}/docker dest=/usr/bin/docker state=link
ignore_errors: true ignore_errors: true
when: "'NoFound' in containerd_svc.stdout and 'NoFound' in docker_svc.stdout" when: "'NoFound' in docker_svc.stdout"
## 可选 ------安装docker查询镜像 tag的小工具---- ## 可选 ------安装docker查询镜像 tag的小工具----
- name: 下载 docker-tag - name: 下载 docker-tag